1
0
mirror of https://github.com/golang/go synced 2024-11-17 07:54:41 -07:00

os/user: simplify test skip for plan9

There's no need to specifically check for runtime.GOOS as there's
already a generic mechanism for that.

Change-Id: I7125443ead456548bd503c5e71cd56e9eb30b446
Reviewed-on: https://go-review.googlesource.com/c/go/+/330750
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
This commit is contained in:
Kir Kolyshkin 2021-06-22 20:19:57 -07:00 committed by Ian Lance Taylor
parent 5d0c2840da
commit 5d5e50c3db
2 changed files with 1 additions and 8 deletions

View File

@ -18,6 +18,7 @@ const (
)
func init() {
userImplemented = false
groupImplemented = false
}

View File

@ -56,10 +56,6 @@ func compare(t *testing.T, want, got *User) {
func TestLookup(t *testing.T) {
checkUser(t)
if runtime.GOOS == "plan9" {
t.Skipf("Lookup not implemented on %q", runtime.GOOS)
}
want, err := Current()
if err != nil {
t.Fatalf("Current: %v", err)
@ -77,10 +73,6 @@ func TestLookup(t *testing.T) {
func TestLookupId(t *testing.T) {
checkUser(t)
if runtime.GOOS == "plan9" {
t.Skipf("LookupId not implemented on %q", runtime.GOOS)
}
want, err := Current()
if err != nil {
t.Fatalf("Current: %v", err)