diff options
author | Jim Meyering <jim@meyering.net> | 1997-08-02 17:10:12 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 1997-08-02 17:10:12 +0000 |
commit | 70611589b3d77d7184bb448620820121c95257bd (patch) | |
tree | f5448dacb071c60dfb5ee9ad2b0a309eb0774950 /tests | |
parent | 94c7a45d8e82982ba37bc355c68ccbf8ebf7f2de (diff) | |
download | coreutils-70611589b3d77d7184bb448620820121c95257bd.tar.xz |
.
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/rm/deep-1 | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/tests/rm/deep-1 b/tests/rm/deep-1 new file mode 100755 index 000000000..84d4ad692 --- /dev/null +++ b/tests/rm/deep-1 @@ -0,0 +1,39 @@ +#!/bin/sh + +# This is a bit of a torture test for mkdir -p, too. + +: ${RM=rm} +: ${MKDIR=mkdir} + +test=deep-1 + +: ${TMPDIR=.} + +if test "$VERBOSE" = yes; then + set -x + $RM --version +fi + +umask 022 + +fail=0 + +tmp=$TMPDIR/t-rm.$$ + +k20=/k/k/k/k/k/k/k/k/k/k/k/k/k/k/k/k/k/k/k/k +k200=$k20$k20$k20$k20$k20$k20$k20$k20$k20$k20 +k400=$k200$k200 + +# Create a directory in $tmp with 400 `k' components. +deep=$tmp/$k400 +$MKDIR -p $deep || fail=1 + +# Make sure the deep dir was created. +test -d $deep || fail=1 + +$RM -r $tmp > $tmp/$test.O || fail=1 + +# Make sure it was deleted. +test -d $deep && fail=1 + +exit $fail |