diff options
author | 2019-07-25 13:59:24 -0700 | |
---|---|---|
committer | 2019-07-25 13:59:24 -0700 | |
commit | f3d508f40e3d85fdbe1dafe8f33782766c88dbdd (patch) | |
tree | 13b14836e2ff36514df0a3456521b11dc448b328 /t/t7300-clean.sh | |
parent | Merge branch 'tg/stash-keep-index-with-removed-paths' (diff) | |
parent | clean: show an error message when the path is too long (diff) | |
download | tgif-f3d508f40e3d85fdbe1dafe8f33782766c88dbdd.tar.xz |
Merge branch 'js/clean-report-too-long-a-path'
"git clean" silently skipped a path when it cannot lstat() it; now
it gives a warning.
* js/clean-report-too-long-a-path:
clean: show an error message when the path is too long
Diffstat (limited to 't/t7300-clean.sh')
-rwxr-xr-x | t/t7300-clean.sh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/t/t7300-clean.sh b/t/t7300-clean.sh index 7b36954d63..a2c45d1902 100755 --- a/t/t7300-clean.sh +++ b/t/t7300-clean.sh @@ -669,4 +669,16 @@ test_expect_success 'git clean -d skips untracked dirs containing ignored files' test_path_is_missing foo/b/bb ' +test_expect_success MINGW 'handle clean & core.longpaths = false nicely' ' + test_config core.longpaths false && + a50=aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa && + mkdir -p $a50$a50/$a50$a50/$a50$a50 && + : >"$a50$a50/test.txt" 2>"$a50$a50/$a50$a50/$a50$a50/test.txt" && + # create a temporary outside the working tree to hide from "git clean" + test_must_fail git clean -xdf 2>.git/err && + # grepping for a strerror string is unportable but it is OK here with + # MINGW prereq + test_i18ngrep "too long" .git/err +' + test_done |