You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
% plz cover
[snip]
31 test targets and 237 tests run in 0s; 209 passed, 28 skipped. Total time 3.44s.
Coverage results:
Total coverage: No data
% plz cover //foo/bar:bar_test
[snip]
//foo/bar:bar_test 59 tests run in 34ms; 59 passed
1 test target and 59 tests run in 0s; 59 passed. Total time 540ms.
Coverage results:
foo/bar:
file1.go 0/10 lines, 0.0%
file2.go 3/39 lines, 7.7%
file3.go 97/107 lines, 90.7%
Total coverage: 100/156 lines, 64.1%
% plz cover
[snip]
31 test targets and 237 tests run in 0s; 209 passed, 28 skipped. Total time 3.42s.
Coverage results:
foo/bar:
file1.go 0/10 lines, 0.0%
file2.go 3/39 lines, 7.7%
file3.go 97/107 lines, 90.7%
Total coverage: 100/156 lines, 64.1%
% plz cover //...
31 test targets and 237 tests run in 0s; 209 passed, 28 skipped. Total time 2m32.3s.
Coverage results:
[snip]
Total coverage: 12076/16719 lines, 72.2%
% plz cover --nocache
[snip]
31 test targets and 237 tests run in 0s; 209 passed, 28 skipped. Total time 4.25s.
Coverage results:
Total coverage: No data
Wait, what? ;)
To take this one step further:
% cd foo/bar
% plz cover
//foo/bar:bar_test 59 tests run in 35ms; 59 passed
1 test target and 59 tests run in 0s; 59 passed. Total time 3.03s.
Coverage results:
foo/bar:
file1.go 0/25 lines, 0.0%
file2.go 0/78 lines, 0.0%
file3.go 0/201 lines, 0.0%
Total coverage: 0/304 lines, 0.0%
% plz cover //foo/bar:bar_test
//foo/bar:bar_test 59 tests run in 31ms; 59 passed
[snip test output]
31 test targets and 237 tests run in 0s; 209 passed, 28 skipped. Total time 3.42s.
Coverage results:
foo/bar:
file1.go 0/10 lines, 0.0%
file2.go 3/39 lines, 7.7%
file3.go 97/107 lines, 90.7%
Total coverage: 100/156 lines, 64.1%
I'm really confused by this output as I expect plz cover to produce coverage information without explicitly adding the //... target. Similarly, having it implicitly include stale coverage data is a bit disturbing. If I manually add random tests via plz cover //targetN, plz cover reports the results. I also expect it to run the coverage tests when I'm in a subdirectory. Thoughts?
The text was updated successfully, but these errors were encountered:
Sorry for the slow reply on this one... it should work as you describe. There's a fairly dumb bug around it not producing coverage when no target is given on the command line, but found a few other things while digging too.
This took me a while to figure out.
Wait, what? ;)
To take this one step further:
I'm really confused by this output as I expect
plz cover
to produce coverage information without explicitly adding the//...
target. Similarly, having it implicitly include stale coverage data is a bit disturbing. If I manually add random tests viaplz cover //targetN
,plz cover
reports the results. I also expect it to run the coverage tests when I'm in a subdirectory. Thoughts?The text was updated successfully, but these errors were encountered: