1
  1. I am using following command for running coverage for complete Java project module.
bazel coverage ... --compilation_mode=dbg --subcommands --announce_rc --verbose_failures --jobs=auto  --sandbox_debug --build_runfile_links --combined_report=lcov --coverage_report_generator=@bazel_tools//tools/test/CoverageOutputGenerator/java/com/google/devtools/coverageoutputgenerator:Main
  1. Then running following command to get html view. Html report is generated in output-directory-name we specified.
genhtml -o <output-directory-name> bazel-out/_coverage/_coverage_report.dat

I wanted to set overall coverage threshold for a project module. Basically Error/Warning should be thrown when this coverage threshold is exceeded. Is there some flag we can use to set this coverage threshold?

rishi007bansod
  • 1,283
  • 2
  • 19
  • 45
  • Did you check with this [experimental_oom_more_eagerly_threshold](https://bazel.build/reference/command-line-reference#flag--experimental_oom_more_eagerly_threshold) ? – SG_Bazel Aug 09 '22 at 04:37
  • @SG_Bazel This is not coverage(lines & function) threshold flag. This seems Memory threshold – rishi007bansod Aug 09 '22 at 07:47

0 Answers0