Skip to content

Commit 0efe54f

Browse files
committed
Let the submodule test add a ':' path on Windows
Git for Windows refuses it with core.protectNTFS on.
1 parent a330d68 commit 0efe54f

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

‎internal/gitcache/mirror_test.go‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,8 @@ func TestMirrorListsSubmodules(t *testing.T) {
270270
runGit(t, work, "add", ".gitmodules")
271271
runGit(t, work, "update-index", "--add", "--cacheinfo", "160000,"+libCommit+",vendor/lib")
272272
runGit(t, work, "update-index", "--add", "--cacheinfo", "160000,"+otherCommit+",third_party/other")
273-
runGit(t, work, "update-index", "--add", "--cacheinfo", "160000,"+libCommit+",:colon")
273+
// Git for Windows refuses ':' in paths unless NTFS protection is off.
274+
runGit(t, work, "-c", "core.protectNTFS=false", "update-index", "--add", "--cacheinfo", "160000,"+libCommit+",:colon")
274275
runGit(t, work, "commit", "--quiet", "-m", "submodules")
275276
runGit(t, work, "push", "--quiet", "origin", "main")
276277
commit := runGit(t, work, "rev-parse", "HEAD")

0 commit comments

Comments
 (0)