1
0
mirror of https://github.com/golang/go synced 2024-09-30 12:18:33 -06:00

cmd/godoc,cmd/gorename,refactor/rename: skip tests on GOOS=android

Change-Id: I7a493ba4c41dddb3049a8e62198d87749fb72f62
Reviewed-on: https://go-review.googlesource.com/c/tools/+/165719
Run-TryBot: Elias Naur <mail@eliasnaur.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
Elias Naur 2019-03-06 10:28:10 +01:00 committed by Brad Fitzpatrick
parent 1f7a77873d
commit ab489119c5
4 changed files with 15 additions and 4 deletions

View File

@ -32,6 +32,10 @@ func buildGodoc(t *testing.T) (bin string, cleanup func()) {
if runtime.GOARCH == "arm" {
t.Skip("skipping test on arm platforms; too slow")
}
if runtime.GOOS == "android" {
t.Skipf("the dependencies are not available on android")
}
tmp, err := ioutil.TempDir("", "godoc-regtest-")
if err != nil {
t.Fatal(err)

View File

@ -312,6 +312,9 @@ func g() { fmt.Println(test.Foo(3)) }
// buildGorename builds the gorename executable.
// It returns its path, and a cleanup function.
func buildGorename(t *testing.T) (tmp, bin string, cleanup func()) {
if runtime.GOOS == "android" {
t.Skipf("the dependencies are not available on android")
}
tmp, err := ioutil.TempDir("", "gorename-regtest-")
if err != nil {

View File

@ -7,12 +7,16 @@ package static
import (
"bytes"
"io/ioutil"
"runtime"
"strconv"
"testing"
"unicode"
)
func TestStaticIsUpToDate(t *testing.T) {
if runtime.GOOS == "android" {
t.Skip("files not available on android")
}
oldBuf, err := ioutil.ReadFile("static.go")
if err != nil {
t.Errorf("error while reading static.go: %v\n", err)

View File

@ -1277,10 +1277,10 @@ func main() {
}
func TestDiff(t *testing.T) {
if runtime.GOOS == "windows" {
t.Skipf("diff tool non-existent for windows on builders")
}
if runtime.GOOS == "plan9" {
switch runtime.GOOS {
case "windows", "android":
t.Skipf("diff tool non-existent for %s on builders", runtime.GOOS)
case "plan9":
t.Skipf("plan9 diff tool doesn't support -u flag")
}