summaryrefslogtreecommitdiff
path: root/tests/rm
diff options
context:
space:
mode:
Diffstat (limited to 'tests/rm')
-rwxr-xr-xtests/rm/fail-2eperm2
-rwxr-xr-xtests/rm/fail-eperm3
-rwxr-xr-xtests/rm/no-give-up2
-rwxr-xr-xtests/rm/one-file-system2
4 files changed, 5 insertions, 4 deletions
diff --git a/tests/rm/fail-2eperm b/tests/rm/fail-2eperm
index bafd5bfcc..66efbce29 100755
--- a/tests/rm/fail-2eperm
+++ b/tests/rm/fail-2eperm
@@ -23,8 +23,8 @@ if test "$VERBOSE" = yes; then
fi
. $srcdir/../lang-default
-PRIV_CHECK_ARG=require-root . $srcdir/../priv-check
. $srcdir/../test-lib.sh
+require_root_
# The containing directory must be owned by the user who eventually runs rm.
chown $NON_ROOT_USERNAME .
diff --git a/tests/rm/fail-eperm b/tests/rm/fail-eperm
index 4abc9dec6..7bc89da15 100755
--- a/tests/rm/fail-eperm
+++ b/tests/rm/fail-eperm
@@ -27,7 +27,8 @@ fi
# searching below. root can simply create the required
# dir/files and run the test as someone else.
-PRIV_CHECK_ARG=require-non-root . $srcdir/../priv-check
+. $srcdir/../test-lib.sh
+skip_if_root_
: ${srcdir=.}
. $srcdir/../require-perl
diff --git a/tests/rm/no-give-up b/tests/rm/no-give-up
index 14d2a4694..8a1ecdc75 100755
--- a/tests/rm/no-give-up
+++ b/tests/rm/no-give-up
@@ -22,8 +22,8 @@ if test "$VERBOSE" = yes; then
rm --version
fi
-PRIV_CHECK_ARG=require-root . $srcdir/../priv-check
. $srcdir/../test-lib.sh
+require_root_
mkdir d || framework_failure
touch d/f || framework_failure
diff --git a/tests/rm/one-file-system b/tests/rm/one-file-system
index 471216c2c..15d327965 100755
--- a/tests/rm/one-file-system
+++ b/tests/rm/one-file-system
@@ -21,9 +21,9 @@ if test "$VERBOSE" = yes; then
rm --version
fi
-PRIV_CHECK_ARG=require-root . $srcdir/../priv-check
. $srcdir/../lang-default
. $srcdir/../test-lib.sh
+require_root_
# If used, these must *follow* test-lib.sh.
cleanup_() { rm -rf "$other_partition_tmpdir"; }