From 0a75914fb787b47cb358ff7a64d749062c14aed2 Mon Sep 17 00:00:00 2001 From: Rob Landley Date: Tue, 20 Nov 2018 17:42:45 -0600 Subject: Fix up some tests for running as a normal user. --- tests/groupadd.test | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'tests/groupadd.test') diff --git a/tests/groupadd.test b/tests/groupadd.test index 091dccf7..6161ee2f 100755 --- a/tests/groupadd.test +++ b/tests/groupadd.test @@ -4,6 +4,13 @@ [ -f testing.sh ] && . testing.sh +if [ "$(id -u)" -ne 0 ] +then + echo "$SHOWSKIP: groupadd (not root)" + continue 2>/dev/null + exit +fi + # 70 characters long string; hereafter, we will use it as per our need. _s70="abcdefghijklmnopqrstuvwxyz123456789abcdefghijklmnopqrstuvwxyz123456789" -- cgit v1.2.3