pub fn measure_python(
root: &Path,
exempt: &[String],
exempt_lines: &BTreeMap<String, BTreeSet<u32>>,
base: Option<&str>,
) -> Result<Vec<Survivor>>Expand description
Run cosmic-ray over the Python project at root and return its un-exempted
survivors — the Python arm of the mutation rule (#203), parity with measure_rust
and measure_typescript.
With base set, only mutants on the <base>...HEAD changed lines are reported:
cosmic-ray has no native git-diff mode, so the run is scoped to the changed .py
files (one session each) and the survivors are then filtered to the changed lines —
line granularity, matching the other arms. Without it, the whole project’s sources
run (tests excluded). exempt is the file-level exempt paths and exempt_lines the
line-scoped ones (#226). cosmic-ray + pytest must be installed.