diff options
author | Ævar Arnfjörð Bjarmason <avarab@gmail.com> | 2021-01-12 21:17:58 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-01-12 23:04:41 +0100 |
commit | 999cfc4f45e90a2eafa9b170d0ab9f0f13cbddb8 (patch) | |
tree | 2a3b1daece11b88c946f4e30243bb798160c80aa /t/t7509-commit-authorship.sh | |
parent | test-lib functions: document arguments to test_commit (diff) | |
download | git-999cfc4f45e90a2eafa9b170d0ab9f0f13cbddb8.tar.xz git-999cfc4f45e90a2eafa9b170d0ab9f0f13cbddb8.zip |
test-lib functions: add --author support to test_commit
Add support for --author to "test_commit". This will simplify some
current and future tests, one of those is being changed here.
Let's also line-wrap the "git commit" command invocation to make diffs
that add subsequent options easier to add, as they'll only need to add
a new option line.
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7509-commit-authorship.sh')
-rwxr-xr-x | t/t7509-commit-authorship.sh | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/t/t7509-commit-authorship.sh b/t/t7509-commit-authorship.sh index 500ab2fe72..ee6c47416e 100755 --- a/t/t7509-commit-authorship.sh +++ b/t/t7509-commit-authorship.sh @@ -18,11 +18,8 @@ message_body () { } test_expect_success '-C option copies authorship and message' ' - echo "Initial" >foo && - git add foo && - test_tick && - git commit -m "Initial Commit" --author Frigate\ \<flying@over.world\> && - git tag Initial && + test_commit --author Frigate\ \<flying@over.world\> \ + "Initial Commit" foo Initial Initial && echo "Test 1" >>foo && test_tick && git commit -a -C Initial && |