Skip to content

Commit

Permalink
go/internal/gcimporter: suppress 3 test cases when gotypesalias=1
Browse files Browse the repository at this point in the history
CL 577715 caused these test cases to fail, but this was not
detected by CI because they are "long" tests.

Updates #66859

Change-Id: I84320d9091772540df2ab15f57d93031596bb89b
Reviewed-on: https://go-review.googlesource.com/c/go/+/579415
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Robert Griesemer <gri@google.com>
Auto-Submit: Alan Donovan <adonovan@google.com>
  • Loading branch information
adonovan authored and gopherbot committed Apr 16, 2024
1 parent 0749672 commit 661f981
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/go/internal/gcimporter/gcimporter_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ package gcimporter_test
import (
"bytes"
"fmt"
"internal/godebug"
"internal/testenv"
"os"
"os/exec"
Expand Down Expand Up @@ -204,6 +205,16 @@ func TestImportTypeparamTests(t *testing.T) {
want := types.ObjectString(checkedObj, types.RelativeTo(checked))
want = sanitizeObjectString(want)

// TODO(golang/go#66859): investigate and reenable these tests,
// which fail with gotypesalias=1, soon to be the default.
if godebug.New("gotypesalias").Value() != "0" {
symbol := name + " in " + filepath.Base(filename)
switch symbol {
case "Eint2 in struct.go", "A in issue50259.go":
t.Skipf("%s requires gotypesalias=1", symbol)
}
}

if got != want {
t.Errorf("imported %q as %q, want %q", name, got, want)
}
Expand Down

0 comments on commit 661f981

Please sign in to comment.