summaryrefslogtreecommitdiff
path: root/tests/test-lib.sh
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test-lib.sh')
-rw-r--r--tests/test-lib.sh1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/test-lib.sh b/tests/test-lib.sh
index 3b8d2ce98..b273f1a81 100644
--- a/tests/test-lib.sh
+++ b/tests/test-lib.sh
@@ -100,6 +100,7 @@ environment variable set to yes. E.g.,
fi
}
+require_root_() { uid_is_privileged_ || skip_test_ "must be run as root"; }
skip_if_root_() { uid_is_privileged_ && skip_test_ "must be run as non-root"; }
error_() { echo "$0: $@" 1>&2; (exit 1); exit 1; }
framework_failure() { error_ 'failure in testing framework'; }