Tools: support reference data in coverage report
This adds initial support for showing the difference between old and new coverage data. The difference is only shown in index.html currently. This is mainly useful when adding new tests right now, to see the impact. To use this, rename the `coverage/analysis` folder in the build directory to `reference`. It will automatically be used by the report script if that reference folder exists.
This commit is contained in:
@@ -62,10 +62,11 @@ def run_report(argv):
|
||||
|
||||
coverage_dir = build_dir / "coverage"
|
||||
analysis_dir = coverage_dir / "analysis"
|
||||
reference_dir = coverage_dir / "reference"
|
||||
report_dir = coverage_dir / "report"
|
||||
|
||||
parse(build_dir, analysis_dir)
|
||||
report_as_html(analysis_dir, report_dir)
|
||||
report_as_html(analysis_dir, report_dir, reference_dir=reference_dir)
|
||||
|
||||
if not args.no_browser:
|
||||
webbrowser.open("file://" + str(report_dir / "index.html"))
|
||||
|
||||
Reference in New Issue
Block a user