summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2018-03-26 03:26:18 -0400
committerJunio C Hamano <gitster@pobox.com>2018-03-26 14:06:08 -0700
commit68d1c2f88ac5524f05f14c24e1c3280bd5134be1 (patch)
treec0e9e45939e9236450bf4746937bd76c38cf0a0b
parent90bbd502d54fe920356fa9278055dc9c9bfe9a56 (diff)
downloadgit-68d1c2f88ac5524f05f14c24e1c3280bd5134be1.tar.gz
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 smart enough to restore the previous value, and just always runs test_unconfig). Signed-off-by: Jeff King <peff@peff.net> Reviewed-by: Eric Sunshine <sunshine@sunshineco.com> Reviewed-by: Jacob Keller <jacob.keller@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rwxr-xr-xt/t3200-branch.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t3200-branch.sh b/t/t3200-branch.sh
index 6c0b7ea4ad..e0c316b71a 100755
--- a/t/t3200-branch.sh
+++ b/t/t3200-branch.sh
@@ -50,7 +50,7 @@ $_z40 $HEAD $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> 1117150200 +0000 branch:
EOF
test_expect_success 'git branch -l d/e/f should create a branch and a log' '
GIT_COMMITTER_DATE="2005-05-26 23:30" \
- git branch -l d/e/f &&
+ git -c core.logallrefupdates=false branch -l d/e/f &&
test_path_is_file .git/refs/heads/d/e/f &&
test_path_is_file .git/logs/refs/heads/d/e/f &&
test_cmp expect .git/logs/refs/heads/d/e/f