mirror of
https://github.com/git/git.git
synced 2025-01-22 15:33:59 +08:00
t5405: use test_must_fail() instead of checking exit code manually
This test expects "git push" to fail, thus it manually inverts that local expected failure into a successful exit code for the test overall. In doing so, it intentionally breaks the &&-chain. Modernize by replacing manual exit code management with test_must_fail() and a normal &&-chain. Signed-off-by: Eric Sunshine <sunshine@sunshineco.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
e5d7e9f516
commit
fbd6ef273e
@ -25,8 +25,7 @@ test_expect_success 'non forced push should die not segfault' '
|
||||
|
||||
(
|
||||
cd another &&
|
||||
git push .. master:master
|
||||
test $? = 1
|
||||
test_must_fail git push .. master:master
|
||||
)
|
||||
|
||||
'
|
||||
|
Loading…
Reference in New Issue
Block a user