Open stuartmscott opened 4 years ago
Darwin Menu Tests are failing on develop when run multiple times:
$ git rev-parse HEAD
a907f129e7b41c03d825c6da3c2fa71ab5b4fb6f
$ go test -count 2 ./...
ok fyne.io/fyne 0.232s
ok fyne.io/fyne/app 0.257s
ok fyne.io/fyne/canvas 0.279s
ok fyne.io/fyne/cmd/fyne 0.234s
? fyne.io/fyne/cmd/fyne/internal/mobile [no test files]
? fyne.io/fyne/cmd/fyne/internal/mobile/binres [no test files]
? fyne.io/fyne/cmd/fyne_demo [no test files]
? fyne.io/fyne/cmd/fyne_demo/data [no test files]
? fyne.io/fyne/cmd/fyne_demo/screens [no test files]
? fyne.io/fyne/cmd/fyne_settings [no test files]
? fyne.io/fyne/cmd/fyne_settings/data [no test files]
ok fyne.io/fyne/cmd/fyne_settings/settings 0.296s
? fyne.io/fyne/cmd/hello [no test files]
ok fyne.io/fyne/dialog 7.661s
ok fyne.io/fyne/driver/desktop 0.175s
? fyne.io/fyne/driver/mobile [no test files]
ok fyne.io/fyne/internal 0.301s
ok fyne.io/fyne/internal/app 0.388s
? fyne.io/fyne/internal/cache [no test files]
ok fyne.io/fyne/internal/driver 0.274s
2020/05/20 20:20:03 Fyne error: Failed to decode image for window icon
2020/05/20 20:20:03 Cause: image: unknown format
2020/05/20 20:20:03 At: /Users/stuartscott/Documents/Projects/Go/src/fyne.io/fyne/internal/driver/glfw/window.go:219
--- FAIL: TestDarwinMenu (0.00s)
panic: runtime error: index out of range [2] with length 2 [recovered]
panic: runtime error: index out of range [2] with length 2
goroutine 301 [running]:
testing.tRunner.func1.1(0x44c7d80, 0xc000258000)
/usr/local/go/src/testing/testing.go:940 +0x2f5
testing.tRunner.func1(0xc00028c000)
/usr/local/go/src/testing/testing.go:943 +0x3f9
panic(0x44c7d80, 0xc000258000)
/usr/local/go/src/runtime/panic.go:969 +0x166
fyne.io/fyne/internal/driver/glfw.resetMainMenu()
/Users/stuartscott/Documents/Projects/Go/src/fyne.io/fyne/internal/driver/glfw/menu_darwin_test.go:134 +0x24d
fyne.io/fyne/internal/driver/glfw.TestDarwinMenu(0xc00028c000)
/Users/stuartscott/Documents/Projects/Go/src/fyne.io/fyne/internal/driver/glfw/menu_darwin_test.go:21 +0xb3
testing.tRunner(0xc00028c000, 0x4526218)
/usr/local/go/src/testing/testing.go:991 +0xdc
created by testing.(*T).Run
/usr/local/go/src/testing/testing.go:1042 +0x357
FAIL fyne.io/fyne/internal/driver/glfw 26.921s
ok fyne.io/fyne/internal/driver/gomobile 1.159s
ok fyne.io/fyne/internal/painter 1.791s
ok fyne.io/fyne/internal/painter/gl 0.211s
ok fyne.io/fyne/internal/painter/software 0.234s
ok fyne.io/fyne/internal/widget 8.626s
ok fyne.io/fyne/layout 0.262s
ok fyne.io/fyne/storage 0.171s
ok fyne.io/fyne/test 0.256s
ok fyne.io/fyne/theme 0.222s
? fyne.io/fyne/tools/playground [no test files]
ok fyne.io/fyne/widget 20.478s
FAIL
@toaster can you take a look?
That menu test is now addressed by PR #1029.
When I tried to run the GLFW tests 10 times it failed after 5 due to the GL context issue that caused your Nil above, so there is still work to do
I can't seem to replicate this on develop
any more, is that just me?
❯ go test ../../internal/driver/glfw/ -count 3
ok fyne.io/fyne/v2/internal/driver/glfw 28.278s
Context:
go test has a parameter '-count n' that executes the tests n times which can be used to find race conditions and sporadic bugs.
Describe the bug:
Running the fyne tests multiple times causes several failures:
To Reproduce:
Steps to reproduce the behaviour:
Device:
Error: