X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=t%2Ft3001-ls-files-others-exclude.sh;h=ae0639d8f3a3fa428dca31df55193487a74b5b57;hb=ea08a6fd194991f9d800e4cac5ae55fdb02dd235;hp=db7a847a5dd13ece7a4ec22d795b8407631d7d4c;hpb=045f5759c97746589a067461e50fad16f60711ac;p=git.git diff --git a/t/t3001-ls-files-others-exclude.sh b/t/t3001-ls-files-others-exclude.sh index db7a847a5..ae0639d8f 100755 --- a/t/t3001-ls-files-others-exclude.sh +++ b/t/t3001-ls-files-others-exclude.sh @@ -3,9 +3,9 @@ # Copyright (c) 2005 Junio C Hamano # -test_description='git-ls-files --others --exclude +test_description='git ls-files --others --exclude -This test runs git-ls-files --others and tests --exclude patterns. +This test runs git ls-files --others and tests --exclude patterns. ' . ./test-lib.sh @@ -59,8 +59,8 @@ echo '!*.2 !*.8' >one/two/.gitignore test_expect_success \ - 'git-ls-files --others with various exclude options.' \ - 'git-ls-files --others \ + 'git ls-files --others with various exclude options.' \ + 'git ls-files --others \ --exclude=\*.6 \ --exclude-per-directory=.gitignore \ --exclude-from=.git/ignore \ @@ -71,12 +71,32 @@ test_expect_success \ printf '*.1\r\n/*.3\r\n!*.6\r\n' >.gitignore test_expect_success \ - 'git-ls-files --others with \r\n line endings.' \ - 'git-ls-files --others \ + 'git ls-files --others with \r\n line endings.' \ + 'git ls-files --others \ --exclude=\*.6 \ --exclude-per-directory=.gitignore \ --exclude-from=.git/ignore \ >output && git diff expect output' +cat > excludes-file << EOF +*.[1-8] +e* +EOF + +git config core.excludesFile excludes-file + +git runstatus | grep "^# " > output + +cat > expect << EOF +# .gitignore +# a.6 +# one/ +# output +# three/ +EOF + +test_expect_success 'git-status honours core.excludesfile' \ + 'diff -u expect output' + test_done