tests: use predetermined NON_ROOT_GID
commitacb422bdd1b325285bb46883f02d8fc6402efd14
authorPádraig Brady <P@draigBrady.com>
Thu, 26 Jun 2014 11:41:01 +0000 (26 12:41 +0100)
committerPádraig Brady <P@draigBrady.com>
Thu, 26 Jun 2014 14:30:41 +0000 (26 15:30 +0100)
tree1f77b51c48cff7532a9227fa3517c5c26eee30be
parente7c7802964cbf0f77a5883808e28eab56e36907b
tests: use predetermined NON_ROOT_GID

* HACKING: GID is more useful in tests than group name, so rename
input param from NON_ROOT_GROUP to NON_ROOT_GID to make it obvious
that only a group ID is now acceptable, thus allowing GID lookups
to be avoided throughout the tests.
* init.cfg (require_root_): Likewise.
* tests/misc/truncate-owned-by-other.sh: Avoid looking up the GID.
* tests/touch/now-owned-by-other.sh: Likewise.
* tests/misc/chroot-credentials.sh: Likewise.  Also fix an instance
of comparison against NON_ROOT_GROUP which would have given a false
failure if a non numeric value was passed in.
* tests/id/setgid.sh: Use previously looked up gid as a more
accurate base for the subsequent adjustment, and move
the uid lookup within chroot, rather than having the overhead
of a separate `id` invocation.
HACKING
init.cfg
tests/id/setgid.sh
tests/misc/chroot-credentials.sh
tests/misc/truncate-owned-by-other.sh
tests/touch/now-owned-by-other.sh