touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
would_clean=$(
cd docs &&
- git clean -n $(pwd)/../src |
+ git clean -n "$(pwd)/../src" |
sed -n -e "s|^Would remove ||p"
) &&
test "$would_clean" = ../src/part3.c || {
test_expect_success 'clean.requireForce defaults to true' '
git config --unset clean.requireForce &&
- ! git-clean
+ test_must_fail git clean
'
test_expect_success 'clean.requireForce' '
git config clean.requireForce true &&
- ! git-clean
+ test_must_fail git clean
'