X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=test%2Fnotmuch-test;h=8e483383f79d67aa7d87c04949e51407ddb7542d;hb=75bdce79527571c12c5de0c630747d6262b73fbd;hp=dbca39ca935633feb0a7af28a0dae03384046939;hpb=73bf7e532e8388416981d9e2378d10ff04264097;p=notmuch diff --git a/test/notmuch-test b/test/notmuch-test index dbca39ca..8e483383 100755 --- a/test/notmuch-test +++ b/test/notmuch-test @@ -42,6 +42,7 @@ fi trap 'e=$?; kill $!; exit $e' HUP INT TERM # Run the tests if test -z "$NOTMUCH_TEST_SERIALIZE" && command -v parallel >/dev/null ; then + test -t 1 && export COLORS_WITHOUT_TTY=t || : if parallel -h | grep -q GNU ; then echo "INFO: running tests with GNU parallel" printf '%s\n' $TESTS | $TEST_TIMEOUT_CMD parallel @@ -49,6 +50,11 @@ if test -z "$NOTMUCH_TEST_SERIALIZE" && command -v parallel >/dev/null ; then echo "INFO: running tests with moreutils parallel" $TEST_TIMEOUT_CMD parallel -- $TESTS fi + RES=$? + if [[ $RES != 0 ]]; then + echo "parallel test suite returned error code $RES" + exit $RES + fi else for test in $TESTS; do $TEST_TIMEOUT_CMD $test "$@" &