Skip to main content

Crate dev_coverage

Crate dev_coverage 

Source
Expand description

§dev-coverage

Test coverage measurement and regression detection for Rust. Part of the dev-* verification suite.

Wraps cargo-llvm-cov (the modern Rust coverage standard) and emits results as dev-report::Report. Detects coverage regressions against a stored baseline so AI agents and CI gates can decide whether a PR drops coverage too far.

§Quick example

use dev_coverage::{CoverageRun, CoverageThreshold};

let run = CoverageRun::new("my-crate", "0.1.0");
let result = run.execute().unwrap();

let threshold = CoverageThreshold::min_line_pct(80.0);
let check = result.into_check_result(threshold);

§Status

Pre-1.0. The 0.9.0 release defines the shape of the API; the actual cargo-llvm-cov integration lands in 0.9.1.

Structs§

CoverageResult
Result of a coverage run.
CoverageRun
Configuration for a coverage run.

Enums§

CoverageError
Errors that can arise during a coverage run.
CoverageThreshold
Threshold defining the minimum acceptable coverage.