From c21fc9d0ab217d6e3cf01ee895e827b72d8207b6 Mon Sep 17 00:00:00 2001 From: Jeff King Date: Fri, 20 Mar 2015 06:11:46 -0400 Subject: t: use test_expect_code instead of hand-rolled comparison This makes our output in the event of a failure slightly nicer, and it means that we do not break the &&-chain. Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- t/t4053-diff-no-index.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 't/t4053-diff-no-index.sh') diff --git a/t/t4053-diff-no-index.sh b/t/t4053-diff-no-index.sh index 2ab3c48734..075ece6db1 100755 --- a/t/t4053-diff-no-index.sh +++ b/t/t4053-diff-no-index.sh @@ -17,8 +17,8 @@ test_expect_success 'setup' ' ' test_expect_success 'git diff --no-index directories' ' - git diff --no-index a b >cnt - test $? = 1 && test_line_count = 14 cnt + test_expect_code 1 git diff --no-index a b >cnt && + test_line_count = 14 cnt ' test_expect_success 'git diff --no-index relative path outside repo' ' -- cgit v1.2.1