]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
Guarantee that exit status trumps output matching.
authorEric Blake <ebb9@byu.net>
Tue, 14 Jul 2009 04:03:27 +0000 (22:03 -0600)
committerEric Blake <ebb9@byu.net>
Tue, 14 Jul 2009 04:03:27 +0000 (22:03 -0600)
* doc/autoconf.texi (Writing Testsuites) <AT_CHECK>: Document this
better.
* tests/autotest.at (Skip, parallel skip): Enhance tests.

Signed-off-by: Eric Blake <ebb9@byu.net>
ChangeLog
doc/autoconf.texi
tests/autotest.at

index f8df09ee97332f40536f5bffa9018e463482196d..37b7b15c2c61a19387068591bbe8b82fb29dd360 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2009-07-13  Eric Blake  <ebb9@byu.net>
 
+       Guarantee that exit status trumps output matching.
+       * doc/autoconf.texi (Writing Testsuites) <AT_CHECK>: Document this
+       better.
+       * tests/autotest.at (Skip, parallel skip): Enhance tests.
+
        Fix nits in recent patches.
        * configure.ac (ac_cv_dir_trailing_space): Avoid $status, for
        zsh.
index aa6ceba420efcab63efd2e582471849d889a9d24..a4aed6f8e93f6187b4f65977e6e7556e300a6c95 100644 (file)
@@ -22750,7 +22750,8 @@ according to the rules of that literal.  Otherwise, the value of the
 parameter is treated as text that must exactly match the output given by
 @var{commands} on standard out and standard error (including an empty
 parameter for no output); any differences are captured in the testsuite
-log and the test is failed.  The difference between @code{AT_CHECK} and
+log and the test is failed (unless an unexpected exit status of 77
+skipped the test instead).  The difference between @code{AT_CHECK} and
 @code{AT_CHECK_UNQUOTED} is that only the latter performs shell variable
 expansion (@samp{$}), command substitution (@samp{`}), and backslash
 escaping (@samp{\}) on comparison text given in the @var{stdout} and
index 0063c4a0c2ec21a007e79b21b2b112b0acffe242..57382ca800b405e813331a73261385a2d6fce48a 100644 (file)
@@ -259,7 +259,7 @@ AT_CHECK_AT_TEST([Fallacy],
   [AT_CHECK([grep failed micro-suite.log], [], [ignore])])
 
 AT_CHECK_AT_TEST([Skip],
-  [AT_CHECK([exit 77], 0, [], [])],
+  [AT_CHECK([echo output; echo irrelevant >&2; exit 77], 0, [mismatch], [])],
   [], [], [], [], [],
   [AT_CHECK([grep skipped micro-suite.log], [], [ignore])])
 
@@ -1155,7 +1155,7 @@ AT_CHECK_AT_TEST([parallel fallacy],
   [AT_CHECK([grep failed micro-suite.log], [], [ignore])], [-j])
 
 AT_CHECK_AT_TEST([parallel skip],
-  [AT_CHECK([exit 77], 0, [], [])],
+  [AT_CHECK([echo output; echo irrelevant >&2; exit 77], 0, [mismatch], [])],
   [], [], [], [], [AT_SKIP_PARALLEL_TESTS],
   [AT_CHECK([grep skipped micro-suite.log], [], [ignore])], [-j])