Agent skill
test-coverage-improver
Run project coverage checks, rank high-risk gaps, and propose high-impact tests to improve regression confidence for changed and critical code paths before release.
Install this agent skill to your Project
npx add-skill https://github.com/rustfs/rustfs/tree/main/.agents/skills/test-coverage-improver
SKILL.md
Test Coverage Improver
Use this skill when you need a prioritized, risk-aware plan to improve tests from coverage results.
Usage assumptions
- Focus scope is either changed lines/files, a module, or the whole repository.
- Coverage artifact must be generated or provided in a supported format.
- If required context is missing, call out assumptions explicitly before proposing work.
Workflow
-
Define scope and baseline
- Confirm target language, framework, and branch.
- Confirm whether the scope is changed files only or full-repo.
-
Produce coverage snapshot
- Rust:
cargo llvm-cov(orcargo tarpaulin) with existing repo config. - JavaScript/TypeScript:
npm test -- --coverageand readcoverage/coverage-final.json. - Python:
pytest --cov=<pkg> --cov-report=jsonand readcoverage.json. - Collect total, per-file, and changed-line coverage.
- Rust:
-
Rank highest-risk gaps
- Prioritize changed code, branch coverage gaps, and low-confidence boundaries.
- Apply the risk rubric in coverage-prioritization.md.
- Keep shortlist to 5–8 gaps.
- For each gap, capture: file, lines, uncovered branches, and estimated risk score.
-
Propose high-impact tests
- For each shortlisted gap, output:
- Intent and expected behavior.
- Normal, edge, and failure scenarios.
- Assertions and side effects to verify.
- Setup needs (fixtures, mocks, integration dependencies).
- Estimated effort (
S/M/L).
- For each shortlisted gap, output:
-
Close with validation plan
- State which gaps remain after proposals.
- Provide concrete verification command and acceptance threshold.
- List assumptions or blockers (environment, fixtures, flaky dependencies).
Output template
Coverage Snapshot
- total / branch coverage
- changed-file coverage
- top missing regions by size
Top Gaps (ranked)
path:line-range| risk score | why critical
Test Proposals
path:line-range- Test name
- scenarios
- assertions
- effort
Validation Plan
- command
- pass criteria
- remaining risk
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
pr-creation-checker
Prepare PR-ready diffs by validating scope, checking required verification steps, drafting a compliant English PR title/body, and surfacing blockers before opening or updating a pull request in RustFS.
code-change-verification
Verify code changes by identifying correctness, regression, security, and performance risks from diffs or patches, then produce prioritized findings with file/line evidence and concrete fixes. Use when reviewing commits, PRs, and merged patches before/after release.
dojo-migrate
Manage world migrations, handle breaking changes, and upgrade Dojo versions. Use when updating deployed worlds, migrating to new versions, or handling schema changes.
dojo-system
Create Dojo systems that implement game logic, modify model state, and handle player actions. Use when implementing game mechanics, player commands, or automated logic.
dojo-review
Review Dojo code for best practices, common mistakes, security issues, and optimization opportunities. Use when auditing models, systems, tests, or preparing for deployment.
dojo-config
Configure Scarb.toml, dojo profiles, world settings, and dependencies. Use when setting up project configuration, managing dependencies, or configuring deployment environments.
Didn't find tool you were looking for?