summaryrefslogtreecommitdiff
path: root/t/op
diff options
context:
space:
mode:
authorDominic Dunlop <domo@computer.org>1998-10-27 22:47:25 +0200
committerJarkko Hietaniemi <jhi@iki.fi>1998-10-28 08:22:04 +0000
commitb9416812b7330d57b47d469866c91cac87d6391b (patch)
tree0ac0a58d7c78806e64921382c3c1fe22347c1272 /t/op
parent824a2ba35a8a435c7dda7b79d43bec16c40e4bd9 (diff)
downloadperl-b9416812b7330d57b47d469866c91cac87d6391b.tar.gz
Re: perl5.004_04 testing problem
Message-ID: <MLIST_v03110700b25b7dc95bbc@[212.24.192.87]> p4raw-id: //depot/cfgperl@2103
Diffstat (limited to 't/op')
-rwxr-xr-xt/op/groups.t16
1 files changed, 5 insertions, 11 deletions
diff --git a/t/op/groups.t b/t/op/groups.t
index 97a41059df..55cf4de4fb 100755
--- a/t/op/groups.t
+++ b/t/op/groups.t
@@ -1,12 +1,8 @@
#!./perl
-if (! -x ($groups = '/usr/ucb/groups') &&
- ! -x ($groups = '/usr/bin/groups') &&
- ! -x ($groups = '/bin/groups') &&
- ! -x ($groups = '/usr/bin/id') &&
- ! -x ($groups = '/bin/id') &&
- ! -x ($groups = '/usr/xpg4/bin/id')
-) {
+$ENV{PATH} = '/bin:/usr/bin:/usr/ucb:/usr/xpg4/bin';
+
+unless (($groups = `(id -Gn || groups) 2>/dev/null`) ne '') {
print "1..0\n";
exit 0;
}
@@ -30,15 +26,13 @@ for (split(' ', $()) {
}
}
-if ($^O eq "uwin") {
+if ($^O eq "uwin") { # Or anybody else who can have spaces in group names.
$gr1 = join(' ', grep(!$did{$_}++, sort split(' ', join(' ', @gr))));
} else {
$gr1 = join(' ', sort @gr);
}
-$groups .= ' -Gn' if $groups =~ m:/id$:;
-
-$gr2 = join(' ', grep(!$basegroup{$_}++, sort split(' ',`$groups`)));
+$gr2 = join(' ', grep(!$basegroup{$_}++, sort split(' ',$groups)));
if ($gr1 eq $gr2) {
print "ok 1\n";