diff options
author | Thomas Rast <trast@inf.ethz.ch> | 2013-03-31 10:37:25 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-04-01 07:45:45 -0700 |
commit | eeb69131ed7f3cb7a191d5bf0e3ce8fdd726a539 (patch) | |
tree | 4be4bdf8bd11633da400b7b2b95efee2c793858b /t/test-lib-functions.sh | |
parent | 95d9d5ec75d3549f00cac29cd33be899cfb4693a (diff) | |
download | git-eeb69131ed7f3cb7a191d5bf0e3ce8fdd726a539.tar.gz |
tests: notice valgrind error in test_must_fail
We tell valgrind to return 126 if it notices that something is wrong,
but we did not actually handle this in test_must_fail, leading to
false negatives. Catch and report it.
Signed-off-by: Thomas Rast <trast@inf.ethz.ch>
Acked-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/test-lib-functions.sh')
-rw-r--r-- | t/test-lib-functions.sh | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/t/test-lib-functions.sh b/t/test-lib-functions.sh index fa62d010f6..6766553c31 100644 --- a/t/test-lib-functions.sh +++ b/t/test-lib-functions.sh @@ -536,6 +536,9 @@ test_must_fail () { elif test $exit_code = 127; then echo >&2 "test_must_fail: command not found: $*" return 1 + elif test $exit_code = 126; then + echo >&2 "test_must_fail: valgrind error: $*" + return 1 fi return 0 } |