coverで解析できるテキスト形式への変換もサポートされている $ go tool covdata percent -i=_coverage main coverage: 83.3% of statements $ go tool covdata textfmt -i=_coverage -o coverage.txt
go test -cover ./... -args -test.gocoverdir=dirname • At the moment -test.gocoverdir is an unexported test flag, but in theory you can hijack it for this purpose.