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 <command>" treats it as
	just another expected failure, which would let such a bug
	go unnoticed.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Jonathan Nieder 2010-10-31 02:36:19 -05:00 коммит произвёл Junio C Hamano
Родитель 2b5ec01845
Коммит 598f0877aa
1 изменённых файлов: 2 добавлений и 3 удалений

Просмотреть файл

@ -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 \