smartystreets / goconvey

Go testing in the browser. Integrates with `go test`. Write behavioral tests in Go.
http://smartystreets.github.io/goconvey/
Other
8.23k stars 554 forks source link

Coverage reports fail w/ go1.20 #672

Closed cognusion closed 1 year ago

cognusion commented 1 year ago

I haven't dug into this, yet, but the coverage reports are no longer rendering. The only output of note from goconvey itself is:

2023/02/03 15:31:56 shell.go:91: Run without coverage

I manually ran with -cover=true but the result was the same. Again, I expect a problem parsing the new format. I'll update after I've dug in a bit.

NajeebTyson commented 1 year ago

I also ran into the same problem with go1.20, when I downgraded the version to go19.9 it worked.

flier commented 1 year ago

It looks like the test output format has changed from go 1.20

PASS
    github.com/flier/gohs/hyperscan coverage: 74.2% of statements
ok      github.com/flier/gohs/hyperscan 0.939s  coverage: 74.2% of statements

The current goconvey assume the coverage: at the beginning of line.

var coverageStatementRE = regexp.MustCompile(`(?m)^coverage: \d+\.\d% of statements(.*)$|^panic: test timed out after `)
cognusion commented 1 year ago

Looks like this was fixed either here or in a recent go version. Thank you (or not)!