t5613: use test_must_fail

Besides being our normal style, this correctly checks for an error exit() versus signal death. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Jeff King committed Oct 3, 2016 at 16:34 UTC 195eb4654631bf6747649e22b0776c988669d829
1 file changed +6 -6
t/t5613-info-alternate.sh
+6 -6
@@ -46,10 +46,9 @@ git clone -l -s F G &&
46 git clone --bare -l -s G H'
47
48 test_expect_success 'invalidity of deepest repository' \
49 -'cd H && {
50 - git fsck
51 - test $? -ne 0
52 -}'
49 +'cd H &&
50 +test_must_fail git fsck
51 +'
52
53 cd "$base_dir"
54
@@ -75,7 +74,8 @@ cd "$base_dir"
74 test_expect_success 'that info/alternates is necessary' \
75 'cd C &&
76 rm -f .git/objects/info/alternates &&
78 -! (git fsck)'
77 +test_must_fail git fsck
78 +'
79
80 cd "$base_dir"
81
@@ -89,7 +89,7 @@ cd "$base_dir"
89 test_expect_success \
90 'that relative alternate is only possible for current dir' '
91 cd D &&
92 - ! (git fsck)
92 + test_must_fail git fsck
93 '
94
95 cd "$base_dir"