Skip to content

Commit 6b15595

Browse files
peffgitster
authored andcommitted
t3200: unset core.logallrefupdates when testing reflog creation
This test checks that the "-l" option creates a reflog. But in fact we'd create one even without it, since the default in a non-bare repository is to do so. Let's unset the config so we can be sure our "-l" option is kicking in. Note that we can't do this with test_config, since that would leave the variable unset after our test finishes, confusing downstream tests (the helper is not not smart enough to restore the previous value, and just always runs test_unconfig). Signed-off-by: Jeff King <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 53f9a3e commit 6b15595

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

t/t3200-branch.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ $ZERO_OID $HEAD $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> 1117150200 +0000 bran
5151
EOF
5252
test_expect_success 'git branch -l d/e/f should create a branch and a log' '
5353
GIT_COMMITTER_DATE="2005-05-26 23:30" \
54-
git branch -l d/e/f &&
54+
git -c core.logallrefupdates=false branch -l d/e/f &&
5555
test_path_is_file .git/refs/heads/d/e/f &&
5656
test_path_is_file .git/logs/refs/heads/d/e/f &&
5757
test_cmp expect .git/logs/refs/heads/d/e/f

0 commit comments

Comments
 (0)