test: test_must_be_empty helper
[gitweb.git] / t / t3001-ls-files-others-exclude.sh
index dc2f0458fd0e74a3dcb4769517f5cde2606eb6f2..efb7ebc91f2f46b38e0c02f4dd11e2224678baea 100755 (executable)
@@ -220,4 +220,22 @@ test_expect_success 'pattern matches prefix completely' '
        test_cmp expect actual
 '
 
+test_expect_success 'ls-files with "**" patterns' '
+       cat <<\EOF >expect &&
+a.1
+one/a.1
+one/two/a.1
+three/a.1
+EOF
+       git ls-files -o -i --exclude "**/a.1" >actual
+       test_cmp expect actual
+'
+
+
+test_expect_success 'ls-files with "**" patterns and no slashes' '
+       : >expect &&
+       git ls-files -o -i --exclude "one**a.1" >actual &&
+       test_cmp expect actual
+'
+
 test_done