(t *testing.T)
| 11 | ) |
| 12 | |
| 13 | func TestGetCommonDir_Primary(t *testing.T) { |
| 14 | repo := t.TempDir() |
| 15 | setupGitRepo(t, repo) |
| 16 | seedInitialCommit(t, repo) |
| 17 | |
| 18 | common, err := GetCommonDir(repo) |
| 19 | require.NoError(t, err) |
| 20 | |
| 21 | want := resolveSymlinks(filepath.Join(repo, ".git")) |
| 22 | assert.Equal(t, want, resolveSymlinks(common)) |
| 23 | } |
| 24 | |
| 25 | func TestGetCommonDir_LinkedWorktree(t *testing.T) { |
| 26 | repo := t.TempDir() |
nothing calls this directly
no test coverage detected