go/packages: only test TestSizes on GOOS where 386 and amd64 GOARCH exists
Fixes solaris/amd64 about missing solaris/386, which isn't a supported port: https://build.golang.org/log/39bfb29694089b7aaa6d0a60cc9bd3360129c2ab Change-Id: If6d9fb368f3236ccf461d5ec47ad3ff4b7ef55b6 Reviewed-on: https://go-review.googlesource.com/c/tools/+/170619 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Michael Matloob <matloob@golang.org>
This commit is contained in:
parent
1aadbdfdbb
commit
8a44e74612
|
@ -1169,6 +1169,13 @@ func testContainsOverlay(t *testing.T, exporter packagestest.Exporter) {
|
|||
// too report the correct sizes function for the actual configuration.
|
||||
func TestSizes(t *testing.T) { packagestest.TestAll(t, testSizes) }
|
||||
func testSizes(t *testing.T, exporter packagestest.Exporter) {
|
||||
// Only run this test on operating systems that have both an amd64 and 386 port.
|
||||
switch runtime.GOOS {
|
||||
case "darwin", "linux", "windows", "freebsd", "openbsd", "android":
|
||||
default:
|
||||
t.Skipf("skipping test on %s", runtime.GOOS)
|
||||
}
|
||||
|
||||
exported := packagestest.Export(t, exporter, []packagestest.Module{{
|
||||
Name: "golang.org/fake",
|
||||
Files: map[string]interface{}{
|
||||
|
|
Loading…
Reference in New Issue