diff options
author | Denton Liu <liu.denton@gmail.com> | 2020-04-20 04:54:41 -0400 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-04-20 13:12:13 -0700 |
commit | e8a5f07d51c5a3081ec65a011681b643ae97b000 (patch) | |
tree | add1107b59037943779ae312019fd701e5e0fd10 | |
parent | t7408: replace incorrect uses of test_must_fail (diff) | |
download | tgif-e8a5f07d51c5a3081ec65a011681b643ae97b000.tar.xz |
t7508: don't use `test_must_fail test_cmp`
The test_must_fail function should only be used for git commands since
we assume that external commands work sanely. Since test_cmp() just
wraps an external command, replace `test_must_fail test_cmp` with
`! test_cmp`.
Signed-off-by: Denton Liu <liu.denton@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rwxr-xr-x | t/t7508-status.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t7508-status.sh b/t/t7508-status.sh index 482ce3510e..8e969f3e36 100755 --- a/t/t7508-status.sh +++ b/t/t7508-status.sh @@ -1471,7 +1471,7 @@ test_expect_success '"status.branch=true" same as "-b"' ' test_expect_success '"status.branch=true" different from "--no-branch"' ' git status -s --no-branch >expected_nobranch && git -c status.branch=true status -s >actual && - test_must_fail test_cmp expected_nobranch actual + ! test_cmp expected_nobranch actual ' test_expect_success '"status.branch=true" weaker than "--no-branch"' ' |