summaryrefslogtreecommitdiff
path: root/tests/touch
diff options
context:
space:
mode:
Diffstat (limited to 'tests/touch')
-rwxr-xr-xtests/touch/now-owned-by-other.sh4
1 files changed, 1 insertions, 3 deletions
diff --git a/tests/touch/now-owned-by-other.sh b/tests/touch/now-owned-by-other.sh
index f5eeda604..d01097edb 100755
--- a/tests/touch/now-owned-by-other.sh
+++ b/tests/touch/now-owned-by-other.sh
@@ -20,11 +20,9 @@
print_ver_ touch
require_root_
-group_num=$(id -g $NON_ROOT_USERNAME)
-
# Create a file owned by root, and writable by $NON_ROOT_USERNAME.
echo > root-owned || framework_failure_
-chgrp +$group_num . root-owned || framework_failure_
+chgrp +$NON_ROOT_GID . root-owned || framework_failure_
chmod g+w root-owned
# Ensure that the current directory is searchable by $NON_ROOT_USERNAME.