diff options
author | Ævar Arnfjörð Bjarmason <avarab@gmail.com> | 2021-01-12 21:18:00 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-01-12 23:04:41 +0100 |
commit | f5d79bf7dd6996b96009ac63b350aa047f2d9959 (patch) | |
tree | 90f3d3f39a2e48de0390a6fc8aea45b11c57d13e /t/t7810-grep.sh | |
parent | test-lib functions: add an --append option to test_commit (diff) | |
download | git-f5d79bf7dd6996b96009ac63b350aa047f2d9959.tar.xz git-f5d79bf7dd6996b96009ac63b350aa047f2d9959.zip |
tests: refactor a few tests to use "test_commit --append"
Refactor a few more tests to use the new "--append" option to
"test_commit". I added it for use in the mailmap tests, but this
demonstrates how useful it is in general.
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7810-grep.sh')
-rwxr-xr-x | t/t7810-grep.sh | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/t/t7810-grep.sh b/t/t7810-grep.sh index 991d5bd9c0..312e0f8cb4 100755 --- a/t/t7810-grep.sh +++ b/t/t7810-grep.sh @@ -687,21 +687,9 @@ test_expect_success 'grep -C1 hunk mark between files' ' ' test_expect_success 'log grep setup' ' - echo a >>file && - test_tick && - GIT_AUTHOR_NAME="With * Asterisk" \ - GIT_AUTHOR_EMAIL="xyzzy@frotz.com" \ - git commit -a -m "second" && - - echo a >>file && - test_tick && - git commit -a -m "third" && - - echo a >>file && - test_tick && - GIT_AUTHOR_NAME="Night Fall" \ - GIT_AUTHOR_EMAIL="nitfol@frobozz.com" \ - git commit -a -m "fourth" + test_commit --append --author "With * Asterisk <xyzzy@frotz.com>" second file a && + test_commit --append third file a && + test_commit --append --author "Night Fall <nitfol@frobozz.com>" fourth file a ' test_expect_success 'log grep (1)' ' |