Skip to content

Commit

Permalink
test_must_fail: 129 is a valid error code from usage()
Browse files Browse the repository at this point in the history
When a git command is run under test_must_fail to make sure that
the argument parser catches bogus command line, it exits with 129.
We need to catch it as a valid "graceful error exit".

Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Junio C Hamano committed Mar 27, 2008
1 parent 5b67b8e commit 8ee002f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion t/test-lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ test_expect_code () {

test_must_fail () {
"$@"
test $? -gt 0 -a $? -le 128
test $? -gt 0 -a $? -le 129
}

# test_cmp is a helper function to compare actual and expected output.
Expand Down

0 comments on commit 8ee002f

Please sign in to comment.