triage_test_coverage
Audit files or directories to get a weakest-first ranked leaderboard of mutation scores, highlighting where the test suite is most fragile.
Instructions
Batch triage: audit a set of files and/or directories and return a weakest-first ranked leaderboard of mutation scores, so you can see where the test suite is most fragile in one call. Directories are recursively expanded to supported source files (.ts/.js/.py/.rs/.php), skipping test files. Files are audited serially. Drill into a weak file with audit_code_resilience for per-mutant survivor detail.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| paths | No | Workspace-relative files and/or directories to triage. Directories are recursively expanded to supported source files. Example: ["src/utils", "src/index.ts"] | |
| diffBase | No | Auto-scope the triage to files changed in git. "HEAD" (uncommitted), "staged", or any ref/branch/SHA (merge-base with HEAD). Makes "paths" optional: diffBase alone scans all changed supported source files; diffBase + paths intersects with those paths. TypeScript files are mutated only on changed lines; other languages run whole-file. Example: "main" | |
| maxFiles | No | Cap on the number of files audited (precedence: this arg > config.defaultMaxFiles > 25). Files beyond the cap are skipped (reported in the summary). Example: 25 | |
| minScore | No | Gate: if any file's mutation score is below this (0–100), the result reports gate.passed=false and lists the failing files. Never causes an error. Example: 80. | |
| timeoutMs | No | Per-file mutation-run timeout in milliseconds. Default: 300000 (5 minutes). | |
| outputFormat | No | Output format. "json" (default) or "text". | |
| fileConcurrency | No | How many files to audit in parallel. Default min(4, cpus-1). When >1, each StrykerJS run's worker count is capped so total CPU use stays near the core count. Example: 4 | |
| mutatorDenylist | No | Stryker mutator names to exclude, applied to every TypeScript/JS file. | |
| survivorsPerFile | No | How many top (severity-ranked, enriched) survivor groups to inline per ranked file. 0 (default) returns a scores-only leaderboard. Example: 3 |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| gate | No | ||
| mode | Yes | ||
| note | Yes | ||
| errors | Yes | ||
| ranking | Yes | ||
| summary | Yes | ||
| scopeNote | No |