diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-02-03 22:25:19 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-02-03 22:25:19 +0300 |
commit | fafca0f72a11bc03263e6f97d07d6f27ea61de48 (patch) | |
tree | 0498cf6b916a833d71ac540c4eec85212ee6ac94 /t/t7004-tag.sh | |
parent | 74dee5cfae1250693447349f3f6bbc26201c5524 (diff) | |
parent | 67c70bd930538890d8eccace72fb0e0a0e565447 (diff) |
Merge branch 'cw/log-updates-for-all-refs-really'
The "core.logAllRefUpdates" that used to be boolean has been
enhanced to take 'always' as well, to record ref updates to refs
other than the ones that are expected to be updated (i.e. branches,
remote-tracking branches and notes).
* cw/log-updates-for-all-refs-really:
doc: add note about ignoring '--no-create-reflog'
update-ref: add test cases for bare repository
refs: add option core.logAllRefUpdates = always
config: add markup to core.logAllRefUpdates doc
Diffstat (limited to 't/t7004-tag.sh')
-rwxr-xr-x | t/t7004-tag.sh | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/t/t7004-tag.sh b/t/t7004-tag.sh index b676b90c7d..072e6c6b88 100755 --- a/t/t7004-tag.sh +++ b/t/t7004-tag.sh @@ -71,6 +71,7 @@ test_expect_success 'creating a tag for an unknown revision should fail' ' # commit used in the tests, test_tick is also called here to freeze the date: test_expect_success 'creating a tag using default HEAD should succeed' ' + test_config core.logAllRefUpdates true && test_tick && echo foo >foo && git add foo && @@ -90,6 +91,13 @@ test_expect_success '--create-reflog does not create reflog on failure' ' test_must_fail git reflog exists refs/tags/mytag ' +test_expect_success 'option core.logAllRefUpdates=always creates reflog' ' + test_when_finished "git tag -d tag_with_reflog" && + test_config core.logAllRefUpdates always && + git tag tag_with_reflog && + git reflog exists refs/tags/tag_with_reflog +' + test_expect_success 'listing all tags if one exists should succeed' ' git tag -l && git tag |