summaryrefslogtreecommitdiff
path: root/t/t4202-log.sh
diff options
context:
space:
mode:
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>2018-07-27 17:48:11 (GMT)
committerJunio C Hamano <gitster@pobox.com>2018-07-30 18:18:41 (GMT)
commitd3c6751b18170276f80e3578d16877d43ad22709 (patch)
tree6fbc19983489ba653109c8bee1b47d95254e7027 /t/t4202-log.sh
parentffc6fa0e396238de3a30623912980263b4f283ab (diff)
downloadgit-d3c6751b18170276f80e3578d16877d43ad22709.zip
git-d3c6751b18170276f80e3578d16877d43ad22709.tar.gz
git-d3c6751b18170276f80e3578d16877d43ad22709.tar.bz2
tests: make use of the test_must_be_empty function
Change various tests that use an idiom of the form: >expect && test_cmp expect actual To instead use: test_must_be_empty actual The test_must_be_empty() wrapper was introduced in ca8d148daf ("test: test_must_be_empty helper", 2013-06-09). Many of these tests have been added after that time. This was mostly found with, and manually pruned from: git grep '^\s+>.*expect.* &&$' t Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4202-log.sh')
-rwxr-xr-xt/t4202-log.sh6
1 files changed, 2 insertions, 4 deletions
diff --git a/t/t4202-log.sh b/t/t4202-log.sh
index 25b1f8c..0b1cd34 100755
--- a/t/t4202-log.sh
+++ b/t/t4202-log.sh
@@ -340,10 +340,9 @@ test_expect_success PCRE 'log -F -E --perl-regexp --grep=<pcre> uses PCRE' '
'
test_expect_success 'log with grep.patternType configuration' '
- >expect &&
git -c grep.patterntype=fixed \
log -1 --pretty=tformat:%s --grep=s.c.nd >actual &&
- test_cmp expect actual
+ test_must_be_empty actual
'
test_expect_success 'log with grep.patternType configuration and command line' '
@@ -1625,9 +1624,8 @@ test_expect_success 'log diagnoses bogus HEAD' '
'
test_expect_success 'log does not default to HEAD when rev input is given' '
- >expect &&
git log --branches=does-not-exist >actual &&
- test_cmp expect actual
+ test_must_be_empty actual
'
test_expect_success 'set up --source tests' '