diff --git a/pkg/git/git_test.go b/pkg/git/git_test.go index 7625b409..d9ce61d0 100644 --- a/pkg/git/git_test.go +++ b/pkg/git/git_test.go @@ -2,7 +2,6 @@ package git import ( "bytes" - "fmt" "os" "os/exec" "path/filepath" @@ -161,9 +160,6 @@ func TestCloneWithOptions(t *testing.T) { err = cmd.Run() assert.Equal(t, err, nil) - // Construct the file URL for the local bare repository - bareRepoURL := fmt.Sprintf("file://%s", bareRepoPath) - // Clone the local bare repository as a normal repository and checkout a commit tmpdir, err := os.MkdirTemp("", "clone_non_bare_repo") assert.Equal(t, err, nil) @@ -173,7 +169,7 @@ func TestCloneWithOptions(t *testing.T) { }() repo, err := CloneWithOpts( - WithRepoURL(bareRepoURL), + WithRepoURL(bareRepoPath), WithCommit("4e59d5852cd76542f9f0ec65e5773ca9f4e02462"), WithWriter(&buf), WithLocalPath(tmpdir),