From: Jonathan Nieder Date: Sun, 31 Oct 2010 07:36:19 +0000 (-0500) Subject: t1400 (update-ref): use test_must_fail X-Git-Tag: v1.7.4-rc0~116^2~7 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=598f0877aa36b5482734091ffef30e21b4e79803;p=git.git t1400 (update-ref): use test_must_fail As t/README explains: When a gitcommand dies due to a segfault, test_must_fail diagnoses it as an error; "! git " treats it as just another expected failure, which would let such a bug go unnoticed. Signed-off-by: Jonathan Nieder Signed-off-by: Junio C Hamano --- diff --git a/t/t1400-update-ref.sh b/t/t1400-update-ref.sh index d17551eb7..ff747f822 100755 --- a/t/t1400-update-ref.sh +++ b/t/t1400-update-ref.sh @@ -52,9 +52,8 @@ rm -f .git/$m test_expect_success \ "fail to create $n" \ - "touch .git/$n_dir - git update-ref $n $A >out 2>err"' - test $? != 0' + "touch .git/$n_dir && + test_must_fail git update-ref $n $A >out 2>err" rm -f .git/$n_dir out err test_expect_success \