mirror of
https://github.com/git/git.git
synced 2026-01-10 10:13:33 +00:00
t1415: move reffiles specific tests to t0601
Move this test into t0601 with other reffiles pack-refs specific tests since it checks for individual loose refs and thus is specific to the reffiles backend. Signed-off-by: John Cai <johncai86@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
@@ -308,4 +308,24 @@ test_expect_success SYMLINKS 'pack symlinked packed-refs' '
|
||||
test "$(test_readlink .git/packed-refs)" = "my-deviant-packed-refs"
|
||||
'
|
||||
|
||||
# The 'packed-refs' file is stored directly in .git/. This means it is global
|
||||
# to the repository, and can only contain refs that are shared across all
|
||||
# worktrees.
|
||||
test_expect_success 'refs/worktree must not be packed' '
|
||||
test_commit initial &&
|
||||
test_commit wt1 &&
|
||||
test_commit wt2 &&
|
||||
git worktree add wt1 wt1 &&
|
||||
git worktree add wt2 wt2 &&
|
||||
git checkout initial &&
|
||||
git update-ref refs/worktree/foo HEAD &&
|
||||
git -C wt1 update-ref refs/worktree/foo HEAD &&
|
||||
git -C wt2 update-ref refs/worktree/foo HEAD &&
|
||||
git pack-refs --all &&
|
||||
test_path_is_missing .git/refs/tags/wt1 &&
|
||||
test_path_is_file .git/refs/worktree/foo &&
|
||||
test_path_is_file .git/worktrees/wt1/refs/worktree/foo &&
|
||||
test_path_is_file .git/worktrees/wt2/refs/worktree/foo
|
||||
'
|
||||
|
||||
test_done
|
||||
|
||||
Reference in New Issue
Block a user