From: Jim Meyering Date: Thu, 22 Dec 2011 11:42:32 +0000 (+0100) Subject: init.sh: avoid unwarranted test failure when using "set -x" X-Git-Tag: v0.1~1350 X-Git-Url: http://erislabs.org.uk/gitweb/?a=commitdiff_plain;h=ed2ad641686263add14f2081d659da0cc3a76536;p=gnulib.git init.sh: avoid unwarranted test failure when using "set -x" * tests/init.sh (compare): Ignore nonzero exit from compare_dev_null_. Otherwise, in a test script that uses "set -x" (like many in vc-dwim) a use like "compare exp out" would get evoke an unconditional failure. --- diff --git a/ChangeLog b/ChangeLog index d52e398eb..fe6ff6a64 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2011-12-22 Jim Meyering + + init.sh: avoid unwarranted test failure when using "set -x" + * tests/init.sh (compare): Ignore nonzero exit from compare_dev_null_. + Otherwise, in a test script that uses "set -x" (like many in vc-dwim) + a use like "compare exp out" would get evoke an unconditional failure. + 2011-12-21 Alfred M. Szmidt bootstrap: fix it to honor $ACLOCAL_FLAGS once again diff --git a/tests/init.sh b/tests/init.sh index 19c0cf4ae..458a44862 100644 --- a/tests/init.sh +++ b/tests/init.sh @@ -304,7 +304,7 @@ fi # Otherwise, propagate $? to caller: any diffs have already been printed. compare () { - compare_dev_null_ "$@" + compare_dev_null_ "$@" || : case $? in 0|1) return $?;; *) compare_ "$@";;