grep: enable recurse-submodules to work on <tree> objects
[gitweb.git] / t / t5613-info-alternate.sh
index 76f1a20e2c2cfb8c6f1971903800ecc959b70eb4..895f46bb9118bbf15d32f594ce79f0e638d25b6a 100755 (executable)
@@ -119,4 +119,21 @@ test_expect_success 'relative duplicates are eliminated' '
        test_cmp expect actual.alternates
 '
 
+test_expect_success CASE_INSENSITIVE_FS 'dup finding can be case-insensitive' '
+       git init --bare insensitive.git &&
+       # the previous entry for "A" will have used uppercase
+       cat >insensitive.git/objects/info/alternates <<-\EOF &&
+       ../../C/.git/objects
+       ../../a/.git/objects
+       EOF
+       cat >expect <<-EOF &&
+       alternate: $(pwd)/C/.git/objects
+       alternate: $(pwd)/B/.git/objects
+       alternate: $(pwd)/A/.git/objects
+       EOF
+       git -C insensitive.git count-objects -v >actual &&
+       grep ^alternate: actual >actual.alternates &&
+       test_cmp expect actual.alternates
+'
+
 test_done