Files

1.0 KiB

Show test coverage from the cached .coverage_baseline file, or rerun the full test suite with $ARGUMENTS.

Usage

  • /coverage — read cached coverage from .coverage_baseline (instant)
  • /coverage run — run script/test_coverage and report fresh results

What it does

Cached mode (default): Reads .coverage_baseline and displays the stored coverage percentage(s). This is instant and does not run any tests.

Run mode (run): Executes script/test_coverage which runs:

  1. Rust tests with cargo llvm-cov (reports line coverage %)
  2. Frontend tests with npm run test:coverage (reports line coverage %)
  3. Computes the overall average and compares to the threshold

Reports Rust coverage, Frontend coverage, Overall coverage, and whether the run passed the threshold.


If the arguments ($ARGUMENTS) equal run, execute bash script/test_coverage from the project root and show the Coverage Summary section from the output. Otherwise, read .coverage_baseline and display the stored coverage value(s).