From: Austin Clements Date: Fri, 19 May 2023 01:46:55 +0000 (-0400) Subject: cmd/cgo/internal/testcarchive: fix nocgo and no-c-archive builds X-Git-Tag: go1.21rc1~433 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=8f1031df779fa31da80b270474a737459dbd1726;p=gostls13.git cmd/cgo/internal/testcarchive: fix nocgo and no-c-archive builds CL 495918 enabled testcarchive much more widely and added many dynamic test skips. CL 495855 added TestDeepStack before these dynamic skips were in. Unfortunately, the two CLs don't logically commute, so when CL 495918 landed, it broke at least nocgo builders and platforms that don't support c-archive builds. Fix this by adding the necessary skips to TestDeepStack. Change-Id: I3d352f731fe67a01c7b96871fde772db8eb21b5d Reviewed-on: https://go-review.googlesource.com/c/go/+/496376 Auto-Submit: Austin Clements TryBot-Result: Gopher Robot Run-TryBot: Austin Clements Reviewed-by: Robert Griesemer --- diff --git a/src/cmd/cgo/internal/testcarchive/carchive_test.go b/src/cmd/cgo/internal/testcarchive/carchive_test.go index a367bca2f1..cdb90fd130 100644 --- a/src/cmd/cgo/internal/testcarchive/carchive_test.go +++ b/src/cmd/cgo/internal/testcarchive/carchive_test.go @@ -1292,6 +1292,10 @@ func TestPreemption(t *testing.T) { // Issue 59294. Test calling Go function from C after using some // stack space. func TestDeepStack(t *testing.T) { + testenv.MustHaveGoBuild(t) + testenv.MustHaveCGO(t) + testenv.MustHaveBuildMode(t, "c-archive") + t.Parallel() if !testWork {