[PATCH 1/1] test: check that expected results file exists when test script exits != 0
Tomi Ollila
tomi.ollila at iki.fi
Mon Jan 13 11:25:56 PST 2014
This way tests continue to run after one test script does not
report success.
---
I failed to notice this when MANUALLY testing the test change in question.
This is quick fix and makes notmuch-test & test-lib.sh have interdependency
how to modify the test script name for output file. I'll think whether
there is something to be made about this, meanwhile I'm open to suggestions
to that. too.
test/notmuch-test | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/test/notmuch-test b/test/notmuch-test
index b843712..ecf81a9 100755
--- a/test/notmuch-test
+++ b/test/notmuch-test
@@ -32,12 +32,14 @@ fi
trap 'e=$?; kill $!; exit $e' HUP INT TERM
# Run the tests
for test in $TESTS; do
+ this_test=${test%.sh}
+ this_test=${this_test#T[0-9][0-9][0-9]-}
$TEST_TIMEOUT_CMD ./$test "$@" &
wait $!
# If the test failed without producing results, then it aborted,
# so we should abort, too.
RES=$?
- if [[ $RES != 0 && ! -e "test-results/${test%.sh}" ]]; then
+ if [[ $RES != 0 && ! -e "test-results/$this_test" ]]; then
exit $RES
fi
done
--
1.8.0
More information about the notmuch
mailing list