-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Have a general mechanism for collecting code coverage #5885
Comments
@iirina I thought i'd post the instructions you left me here incase someone else is after a way to integrate with If the rules are written in Starlark, something helpful can be:
Bazel generates coverage reports in the lcov format. To work well with Bazel, your test rules also have to generate lcov reports under COVERAGE_DIR directory. Your test rule has to define the $lcov_merger attrbiute (similar to how Java tests do ) bazel/src/main/java/com/google/devtools/build/lib/bazel/rules/java/BazelJavaTestRule.java Line 70 in 17794d5
|
One thing that came up today - with this design of coverage collection is it possible to have another rule depend on the coverage output? We would like to write another rule that depends on the output and then creates a script that will upload the report on |
@iirina I'm taking another look at this but I havn't been able to figure out how to get |
is there any update for this feature? |
Is there any update on this? We desperately need code coverage with non-lcov tools. Is there at least some workaround where you define your toolchain and keep the instrumentation files and instrumentation executions with arbitrary extensions (e.g. |
Thank you for contributing to the Bazel repository! This issue has been marked as stale since it has not had any activity in the last 1+ years. It will be closed in the next 90 days unless any other activity occurs. If you think this issue is still relevant and should stay open, please post any comment here and the issue will no longer be marked as stale. |
Not stale |
Code coverage support in Bazel is poor and one reason is the lack of a general mechanism for collecting the code coverage information.
As briefly described in Bazel coverage design doc, the next steps towards a more general solution are:
coverage_toolchain
The text was updated successfully, but these errors were encountered: