From: Paul Eggert Date: Fri, 16 Nov 2007 23:04:08 +0000 (+0100) Subject: Port tests/rmdir/ignore away from GNU/Linux. X-Git-Tag: v6.9.90~46 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6076d0ae2fdae2ebaac6d5a6c793539615471742;p=thirdparty%2Fcoreutils.git Port tests/rmdir/ignore away from GNU/Linux. * tests/rmdir/ignore: Don't assume that rmdir($PWD) will fail with errno==ENOTEMPTY when $PWD is not empty; Posix also allows rmdir to fail with errno==EBUSY. --- diff --git a/ChangeLog b/ChangeLog index 46deded149..0e6c87a346 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2007-11-16 Paul Eggert + + Port tests/rmdir/ignore away from GNU/Linux. + * tests/rmdir/ignore: Don't assume that rmdir($PWD) will fail + with errno==ENOTEMPTY when $PWD is not empty; Posix also allows + rmdir to fail with errno==EBUSY. + 2007-11-16 Jim Meyering Avoid an obscure new "make distcheck" failure. diff --git a/tests/rmdir/ignore b/tests/rmdir/ignore index 5acc786cbd..6ad89577c6 100755 --- a/tests/rmdir/ignore +++ b/tests/rmdir/ignore @@ -24,14 +24,14 @@ fi . $srcdir/../test-lib.sh cwd=`pwd` -mkdir -p $cwd/a/b $cwd/x || framework_failure +mkdir -p $cwd/a/b/c $cwd/a/x || framework_failure fail=0 -rmdir -p --ignore-fail-on-non-empty $cwd/a/b || fail=1 -# $cwd/x should remain -test -d $cwd/x || fail=1 -# $cwd/{a,b} should be gone -test -d $cwd/a && fail=1 +rmdir -p --ignore-fail-on-non-empty $cwd/a/b/c || fail=1 +# $cwd/a/x should remain +test -d $cwd/a/x || fail=1 +# $cwd/a/b and $cwd/a/b/c should be gone test -d $cwd/a/b && fail=1 +test -d $cwd/a/b/c && fail=1 exit $fail