misc/cgo/test: skip Test9400 on Alpine

Alpine has a known issue where setgid clobbers the Go stack (#39857).
misc/cgo/test skips other tests that use setgid on Alpine, but not
this one. It's not clear to me why this test *used to* pass, but when
I refactored misc/cgo/test in CL 447355 it started failing.

Disable this test on Alpine, like the other setgid tests.

Change-Id: I2e646ef55e2201a4f0b377319d719a011ec847f0
Reviewed-on: https://go-review.googlesource.com/c/go/+/448355
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Austin Clements <austin@google.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
This commit is contained in:
Austin Clements 2022-11-07 10:24:23 -05:00
parent e7422b0591
commit 42105eb8a5

View file

@ -30,7 +30,14 @@ func TestSetgidStress(t *testing.T) {
testSetgidStress(t)
}
func Test1435(t *testing.T) { test1435(t) }
func Test6997(t *testing.T) { test6997(t) }
func Test9400(t *testing.T) { test9400(t) }
func Test1435(t *testing.T) { test1435(t) }
func Test6997(t *testing.T) { test6997(t) }
func Test9400(t *testing.T) {
if _, err := os.Stat("/etc/alpine-release"); err == nil {
t.Skip("setgid is broken with musl libc - go.dev/issue/39857")
}
test9400(t)
}
func TestBuildID(t *testing.T) { testBuildID(t) }