aboutsummaryrefslogtreecommitdiff
path: root/tests/id.test
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2019-11-04 10:25:35 -0800
committerRob Landley <rob@landley.net>2019-11-04 22:14:00 -0600
commita0a51dee7cc2b39154f4272430a963f3ebbf222e (patch)
tree7d40283ec51ef67d464b6a870666e96f524a0c82 /tests/id.test
parent126c317d5ceee7802d52fc6be1b695f759aa6725 (diff)
downloadtoybox-a0a51dee7cc2b39154f4272430a963f3ebbf222e.tar.gz
id: various fixes.
Handle unknown groups (fixes #117). Fix -G to show *all* groups, not just all supplementary groups. Fix -Z output to not include "context=".
Diffstat (limited to 'tests/id.test')
-rwxr-xr-xtests/id.test3
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/id.test b/tests/id.test
index 6d0f63a8..f62938f0 100755
--- a/tests/id.test
+++ b/tests/id.test
@@ -6,5 +6,8 @@
testing "id 0" "id 0" "uid=0(root) gid=0(root) groups=0(root)\n" "" ""
testing "id root" "id root" "uid=0(root) gid=0(root) groups=0(root)\n" "" ""
+testing "id -G root" "id -G root" "0\n" "" ""
+testing "id -g root" "id -g root" "0\n" "" ""
+testing "id -u root" "id -u root" "0\n" "" ""
testing "id no-such-user" "id no-such-user 2>/dev/null ; echo \$?" "1\n" "" ""
testing "id 9999999" "id 9999999 2>/dev/null ; echo \$?" "1\n" "" ""