README.rst
1.. _#2127: https://github.com/bazelbuild/rules_go/issues/2127
2
3coverage functionality
4======================
5
6coverage_test
7-------------
8
9Checks that ``bazel coverage`` on a ``go_test`` produces reasonable output.
10Libraries referenced by the test that pass ``--instrumentation_filter`` should
11have coverage data. Library excluded with ``--instrumentatiuon_filter`` should
12not have coverage data.
13
14binary_coverage_test
15--------------------
16
17Checks that ``bazel build --collect_code_coverage`` can instrument a
18``go_binary``. ``bazel coverage`` should also work, though it should fail
19with status 4 since the binary is not a test.
20
21This functionality isn't really complete. The generate test main package
22gathers and writes coverage data, and that's not present. This is just
23a regression test for a link error (`#2127`_).
24