summaryrefslogtreecommitdiff
path: root/tests/vars3.test
diff options
context:
space:
mode:
authorRalf Wildenhues <Ralf.Wildenhues@gmx.de>2008-09-06 19:20:32 +0200
committerRalf Wildenhues <Ralf.Wildenhues@gmx.de>2008-09-06 19:38:34 +0200
commit20594c08f633aaee1df952242ea78553037758b9 (patch)
treec3aa9ca7e34401a717011279209386fe12c105ee /tests/vars3.test
parentc327d0d37c64dd126c71d3ffbf7eb8a3fe00c8c1 (diff)
downloadautomake-20594c08f633aaee1df952242ea78553037758b9.tar.gz
Use `Exit' instead of `exit' in test suite.
Cater to Bourne shells like Solaris sh that do not pass the `exit' argument as status to the cleanup trap. * Makefile.am (maintainer-check): Check that here-documents use only `END' or `EOF' as delimiter in the test suite. Check that, outside of here-documents, the tests do not use `exit' with an argument, but use `Exit' instead. * tests/defs.in (Exit): New function. Use it throughout, starting with the introduction of the exit trap. * tests/*.test: Use `Exit $arg' instead of `exit $arg' throughout, except inside created files. Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
Diffstat (limited to 'tests/vars3.test')
-rwxr-xr-xtests/vars3.test22
1 files changed, 11 insertions, 11 deletions
diff --git a/tests/vars3.test b/tests/vars3.test
index 79f8cdd0d..4eb2e6493 100755
--- a/tests/vars3.test
+++ b/tests/vars3.test
@@ -17,7 +17,7 @@
# Check that Automake warns about variables containing spaces
# and other non-POSIX characters.
-. ./defs || exit 1
+. ./defs || Exit 1
set -e
@@ -46,32 +46,32 @@ cat stderr
# No error expected for these lines.
grep 1: stderr
-grep 2: stderr && exit 1
-grep 3: stderr && exit 1
+grep 2: stderr && Exit 1
+grep 3: stderr && Exit 1
grep 4: stderr
grep 5: stderr
-grep 6: stderr && exit 1
+grep 6: stderr && Exit 1
grep 7: stderr
grep 8: stderr
grep 9: stderr
-grep 10: stderr && exit 1
-grep 11: stderr && exit 1
-grep 12: stderr && exit 1
+grep 10: stderr && Exit 1
+grep 11: stderr && Exit 1
+grep 12: stderr && Exit 1
# Now check some individual values.
grep 'shell echo' stderr
-grep 'nextvariableisbad' stderr && exit 1
+grep 'nextvariableisbad' stderr && Exit 1
grep 'addsuffix' stderr
grep 'bad boy' stderr
-grep 'ok' stderr && exit 1
+grep 'ok' stderr && Exit 1
grep 'three errors' stderr
grep 'on this' stderr
grep 'long line' stderr
grep 'o u c h' stderr
grep 'wildcard' stderr
grep 'another error' stderr
-grep 'thisis' stderr && exit 1
-grep 'here' stderr && exit 1
+grep 'thisis' stderr && Exit 1
+grep 'here' stderr && Exit 1
# None of these errors be diagnosed with -Wno-portability
$AUTOMAKE -Wno-portability