From: Junio C Hamano Date: Mon, 27 Aug 2018 21:33:43 +0000 (-0700) Subject: Merge branch 'sg/test-must-be-empty' X-Git-Tag: v2.19.0-rc1~15 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/986c5181071ce3aac42d0aaeb7bd691a1a0bdf4a?hp=--cc Merge branch 'sg/test-must-be-empty' Test fixes. * sg/test-must-be-empty: tests: use 'test_must_be_empty' instead of 'test_cmp ' tests: use 'test_must_be_empty' instead of 'test_cmp /dev/null ' tests: use 'test_must_be_empty' instead of 'test ! -s' tests: use 'test_must_be_empty' instead of '! test -s' --- 986c5181071ce3aac42d0aaeb7bd691a1a0bdf4a diff --cc t/t7810-grep.sh index d826e24b45,c82c8f5f72..be5c1bd553 --- a/t/t7810-grep.sh +++ b/t/t7810-grep.sh @@@ -954,9 -932,10 +947,9 @@@ test_expect_success 'grep from a subdir test_expect_success 'grep from a subdirectory to search wider area (2)' ' mkdir -p s && ( - cd s || exit 1 - ( git grep xxyyzz .. >out ; echo $? >status ) - test_must_be_empty out && - test 1 = $(cat status) + cd s && + test_expect_code 1 git grep xxyyzz .. >out && - ! test -s out ++ test_must_be_empty out ) '