panic by test packages without test files
diiimo1973 opened this issue · 0 comments
diiimo1973 commented
my-package has no testfiles
gocov test github.com/my-package | gocov-html
panic: runtime error: index out of range
goroutine 1 [running]:
github.com/matm/gocov-html/cov.printReport(0x44d218, 0xc82002c010, 0xc82003be00)
github.com/matm/gocov-html/cov/report.go:163 +0xa0c
github.com/matm/gocov-html/cov.HTMLReportCoverage(0x44d2e8, 0xc82002c008, 0x0, 0x0, 0x0, 0x0)
github.com/matm/gocov-html/cov/report.go:276 +0x49f
main.main()
gopkg.in/matm/v1/gocov-html/gocov-html.go:50 +0xfb
The same with the XML reporter works:
gocov test github.com/my-package | gocov-xml