diff options
| author | Bryan C. Mills <bcmills@google.com> | 2019-11-08 10:52:10 -0500 |
|---|---|---|
| committer | Bryan C. Mills <bcmills@google.com> | 2019-11-08 16:31:00 +0000 |
| commit | a782472dcd3937d8e49ab843dffc7568c6eb8edb (patch) | |
| tree | ce222d1c4500509388401981ffc215998db7b83e /src | |
| parent | ae4534e6598fe905d3ebefae44afef07e853b1d0 (diff) | |
| download | go-a782472dcd3937d8e49ab843dffc7568c6eb8edb.tar.xz | |
cmd/go: delete flaky TestQEMUUserMode
If QEMU user-mode is actually a supported configuration, then per
http://golang.org/wiki/PortingPolicy it needs to have a builder
running tests for all packages, not just a simple “hello world”
program.
Updates #1508
Updates #13024
Fixes #35457
Change-Id: Ib6122b06ad1d265550a0e92131506266495893cc
Reviewed-on: https://go-review.googlesource.com/c/go/+/206137
Run-TryBot: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Diffstat (limited to 'src')
| -rw-r--r-- | src/cmd/go/go_test.go | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/src/cmd/go/go_test.go b/src/cmd/go/go_test.go index 5ff50556c2..1016a737a0 100644 --- a/src/cmd/go/go_test.go +++ b/src/cmd/go/go_test.go @@ -5185,52 +5185,6 @@ func TestUpxCompression(t *testing.T) { } } -// Test that Go binaries can be run under QEMU in user-emulation mode -// (See issue #13024). -func TestQEMUUserMode(t *testing.T) { - if testing.Short() && testenv.Builder() == "" { - t.Skipf("skipping in -short mode on non-builder") - } - - testArchs := []struct { - g, qemu string - }{ - {"arm", "arm"}, - {"arm64", "aarch64"}, - } - - tg := testgo(t) - defer tg.cleanup() - tg.tempFile("main.go", `package main; import "fmt"; func main() { fmt.Print("hello qemu-user") }`) - tg.parallel() - src, obj := tg.path("main.go"), tg.path("main") - - for _, arch := range testArchs { - arch := arch - t.Run(arch.g, func(t *testing.T) { - qemu := "qemu-" + arch.qemu - testenv.MustHaveExecPath(t, qemu) - - out, err := exec.Command(qemu, "--version").CombinedOutput() - if err != nil { - t.Fatalf("%s --version failed: %v", qemu, err) - } - - tg.setenv("GOARCH", arch.g) - tg.run("build", "-o", obj, src) - - out, err = exec.Command(qemu, obj).CombinedOutput() - if err != nil { - t.Logf("%s output:\n%s\n", qemu, out) - t.Fatalf("%s failed with %v", qemu, err) - } - if want := "hello qemu-user"; string(out) != want { - t.Errorf("bad output from %s:\ngot %s; want %s", qemu, out, want) - } - }) - } -} - func TestCacheListStale(t *testing.T) { tooSlow(t) if strings.Contains(os.Getenv("GODEBUG"), "gocacheverify") { |
