+2011-06-24 Stefano Lattarini <stefano.lattarini@gmail.com>
+
+ tests: make 'subst-no-trailing-empty-line.test' more robust
+ * tests/subst-no-trailing-empty-line.test: Strengthen existing
+ checks, to try more scenarios and be slightly stricter in some
+ grepping checks.
+
2011-06-24 Stefano Lattarini <stefano.lattarini@gmail.com>
tests: fix an incomplete comment
CC = false
EXEEXT =
+## The "x" and "zardoz" strings and the use of '+=' are there to ensure
+## that these variables get rewritten by Automake.
noinst_PROGRAMS = x @$v1@ @$v2@ @$v3@
-bin_PROGRAMS = @A@ mu @$v2@ @$v3@
+bin_PROGRAMS = @A@
+bin_PROGRAMS += @$v1@ @$v2@ @$v3@
check_PROGRAMS = zardoz \$(noinst_PROGRAMS)
## Required whenever there are @substituted@ values in the
# For debugging.
$EGREP -n 'ABCD|am__empty' Makefile.in
# Sanity check.
-test `$EGREP -c "^[ $tab]*@$v2@ @$v3@[ $tab]*$bs?$" Makefile.in` -eq 2
+test `$EGREP -c "^[ $tab]*@$v2@ @$v3@[ $tab]*$bs?$" Makefile.in` -eq 3
./configure
{
- sed -n '/^noinst_PROGRAMS =/,/[^\\]$/p' Makefile
- sed -n '/^bin_PROGRAMS =/,/[^\\]$/p' Makefile
- sed -n '/^check_PROGRAMS =/,/[^\\]$/p' Makefile
+ sed -n '/^noinst_PROGRAMS *=/,/[^\\]$/p' Makefile
+ sed -n '/^bin_PROGRAMS *=/,/[^\\]$/p' Makefile
+ sed -n '/^check_PROGRAMS *=/,/[^\\]$/p' Makefile
+ sed -n '/^am__EXEEXT.*=/,/[^\\]$/p' Makefile
} >t-programs
cat t-programs
grep '^ *$' t-programs && Exit 1
$MAKE print-programs >stdout || { cat stdout; Exit 1; }
cat stdout
grep '^BEG1: x :END1$' stdout
-grep '^BEG2: mu :END2$' stdout
+grep '^BEG2: :END2$' stdout
grep '^BEG3: zardoz x :END3$' stdout
am__empty=X $MAKE -e print-programs >stdout || { cat stdout; Exit 1; }
cat stdout
grep '^BEG1: x X :END1$' stdout
-grep '^BEG2: mu X :END2$' stdout
+grep '^BEG2: X :END2$' stdout
grep '^BEG3: zardoz x X :END3$' stdout
: