Merge branch 'ja/directory-attrs'
[gitweb.git] / t / t1450-fsck.sh
index 0b5c30b4d95cf2f94f706188fb1841ad8c8e3459..d730734fde8e4de69fdf2662915bc67342198fc8 100755 (executable)
@@ -253,4 +253,19 @@ test_expect_success 'fsck notices "." and ".." in trees' '
        )
 '
 
+test_expect_success 'fsck notices ".git" in trees' '
+       (
+               git init dotgit &&
+               cd dotgit &&
+               blob=$(echo foo | git hash-object -w --stdin) &&
+               tab=$(printf "\\t") &&
+               git mktree <<-EOF &&
+               100644 blob $blob$tab.git
+               EOF
+               git fsck 2>out &&
+               cat out &&
+               grep "warning.*\\.git" out
+       )
+'
+
 test_done