Skip to content

Commit 2b6f0b0

Browse files
sbohrergitster
authored andcommitted
git clean: Add test to verify directories aren't removed with a prefix
Signed-off-by: Shawn Bohrer <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent f2d0df7 commit 2b6f0b0

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

t/t7300-clean.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,15 +75,16 @@ test_expect_success 'git-clean src/ src/' '
7575

7676
test_expect_success 'git-clean with prefix' '
7777
78-
mkdir -p build docs &&
79-
touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
78+
mkdir -p build docs src/test &&
79+
touch a.out src/part3.c docs/manual.txt obj.o build/lib.so src/test/1.c &&
8080
(cd src/ && git-clean) &&
8181
test -f Makefile &&
8282
test -f README &&
8383
test -f src/part1.c &&
8484
test -f src/part2.c &&
8585
test -f a.out &&
8686
test ! -f src/part3.c &&
87+
test -f src/test/1.c &&
8788
test -f docs/manual.txt &&
8889
test -f obj.o &&
8990
test -f build/lib.so

0 commit comments

Comments
 (0)