Skip to content

Commit 70efe9f

Browse files
crypto/x509: make TestIssue51759 builder only
Since we can't gate tests on the macOS version on normal machines, restrict TestIssue51759 to only run on builders, where we have a way to do this. Change-Id: I70fc83c587689b499b6a38864973a77bb3e52596 Reviewed-on: https://go-review.googlesource.com/c/go/+/472619 TryBot-Result: Gopher Robot <[email protected]> Reviewed-by: Bryan Mills <[email protected]> Run-TryBot: Roland Shoemaker <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]>
1 parent f1ea024 commit 70efe9f

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/crypto/x509/verify_test.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1860,7 +1860,11 @@ func TestIssue51759(t *testing.T) {
18601860
if runtime.GOOS != "darwin" {
18611861
t.Skip("only affects darwin")
18621862
}
1863-
if builder := testenv.Builder(); builder == "darwin-amd64-10_14" || builder == "darwin-amd64-10_15" {
1863+
builder := testenv.Builder()
1864+
if builder == "" {
1865+
t.Skip("only run this test on the builders, as we have no reasonable way to gate tests on macOS versions elsewhere")
1866+
}
1867+
if builder == "darwin-amd64-10_14" || builder == "darwin-amd64-10_15" {
18641868
t.Skip("behavior only enforced in macOS 11 and after")
18651869
}
18661870
// badCertData contains a cert that we parse as valid

0 commit comments

Comments
 (0)