Expand description
LCOV-based coverage analysis for change request diffs.
Pure functions that parse LCOV reports, extract changed lines from unified diffs, and classify test coverage severity. No I/O — all inputs are string slices provided by the CLI layer.
classify_coverage_severity is formally verified by Creusot in
gh-verify-verif.
Structs§
- Coverage
Analysis - Aggregate coverage analysis for the entire change request.
- Coverage
Report - Parsed coverage report, format-agnostic intermediate representation.
- File
Analysis - Per-file coverage analysis result for change request changed lines.
- File
Coverage - Per-file coverage data. Corresponds to one SF..end_of_record block in LCOV.
Enums§
- Parse
Error - LCOV parse error. Explicit enum (no anyhow in core crate).
Functions§
- analyze_
coverage - Analyze coverage of change request changed lines against a parsed report.
- classify_
coverage_ severity - Classify coverage severity using integer arithmetic (no f64).
- extract_
changed_ lines - Extract added line numbers from a unified diff patch.
- parse_
lcov - Parse LCOV format content into a
CoverageReport. - resolve_
path - Check whether an LCOV path (often absolute) matches a change request path (relative).