From 442849e1209904a1fd7eee3448dc770393c9f83b Mon Sep 17 00:00:00 2001 From: Hajime Hoshi Date: Mon, 24 Aug 2020 04:10:22 +0900 Subject: [PATCH] ebiten: Skip some tests on Wasm They are flagile and sometimes causes crash on GitHub Actions workflow tests. --- image_test.go | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/image_test.go b/image_test.go index 97dd17892..afbfe2efd 100644 --- a/image_test.go +++ b/image_test.go @@ -22,9 +22,7 @@ import ( "image/draw" _ "image/png" "math" - "regexp" "runtime" - "strconv" "testing" . "github.com/hajimehoshi/ebiten" @@ -44,18 +42,8 @@ func skipTooSlowTests(t *testing.T) bool { return true } if runtime.GOOS == "js" { - v := runtime.Version() - if m := regexp.MustCompile(`^go(\d+)\.(\d+)`).FindStringSubmatch(v); m != nil { - major, _ := strconv.Atoi(m[1]) - minor, _ := strconv.Atoi(m[2]) - - // In Go1.12, converting JS arrays from/to slices uses TypedArrayOf, and this might allocates - // too many ArrayBuffers. - if major == 1 && minor <= 12 { - t.Skipf("too slow on Go%d.%dWasm", major, minor) - return true - } - } + t.Skip("too slow or fragile on Wasm") + return true } return false }