diff options
author | Junio C Hamano <gitster@pobox.com> | 2022-05-21 01:26:54 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2022-05-21 01:26:54 +0300 |
commit | 6b3d47a960c2b7801d1daad4af876cda33f277dc (patch) | |
tree | 6922cc30b1d2685ce35d85dbcb9b65200f2f2a64 /t | |
parent | ee0241bd224d3c106701876d1cceecf17b6039e3 (diff) | |
parent | 82b28c4ed802bbf96262e5416916441184cd2d4b (diff) |
Merge branch 'km/t3501-use-test-helpers'
Test script updates.
* km/t3501-use-test-helpers:
t3501: remove test -f and stop ignoring git <cmd> exit code
Diffstat (limited to 't')
-rwxr-xr-x | t/t3501-revert-cherry-pick.sh | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/t/t3501-revert-cherry-pick.sh b/t/t3501-revert-cherry-pick.sh index 8617efaaf1..9eb19204ac 100755 --- a/t/t3501-revert-cherry-pick.sh +++ b/t/t3501-revert-cherry-pick.sh @@ -66,8 +66,7 @@ test_expect_success 'cherry-pick after renaming branch' ' git checkout rename2 && git cherry-pick added && - test $(git rev-parse HEAD^) = $(git rev-parse rename2) && - test -f opos && + test_cmp_rev rename2 HEAD^ && grep "Add extra line at the end" opos && git reflog -1 | grep cherry-pick @@ -77,9 +76,9 @@ test_expect_success 'revert after renaming branch' ' git checkout rename1 && git revert added && - test $(git rev-parse HEAD^) = $(git rev-parse rename1) && - test -f spoo && - ! grep "Add extra line at the end" spoo && + test_cmp_rev rename1 HEAD^ && + test_path_is_file spoo && + test_cmp_rev initial:oops HEAD:spoo && git reflog -1 | grep revert ' |