clean: respect pathspecs with "-d"
[gitweb.git] / t / t6131-pathspec-icase.sh
index 3215eef5253ca9f0a34f217a7af3f0b067df711c..a7c7ff5f4938c1fa7439e7c5a45321572bfc55fe 100755 (executable)
@@ -3,6 +3,12 @@
 test_description='test case insensitive pathspec limiting'
 . ./test-lib.sh
 
+if test_have_prereq CASE_INSENSITIVE_FS
+then
+       skip_all='skipping case sensitive tests - case insensitive file system'
+       test_done
+fi
+
 test_expect_success 'create commits with glob characters' '
        test_commit bar bar &&
        test_commit bAr bAr &&
@@ -94,4 +100,10 @@ test_expect_success 'match_pathspec_depth matches :(icase)bar with empty prefix'
        test_cmp expect actual
 '
 
+test_expect_success '"git diff" can take magic :(icase) pathspec' '
+       echo FOO/BAR >expect &&
+       git diff --name-only HEAD^ HEAD -- ":(icase)foo/bar" >actual &&
+       test_cmp expect actual
+'
+
 test_done