agentleFS
0xrohan100xrohan10/skills/test-value-audit/SKILL.md

test-value-audit

Skill2 starsChanged 4 months agoMITView on GitHub

Audit test value. Use when the user asks to review tests for regression value or prune low-value unit and integration tests.

2 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 5 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈5

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use the tests, module, or suite named by the user as the audit boundary.

    line 12
  2. Distinctive:

    Read the in-scope tests, the production code they exercise, neighboring unit and integration tests, and any comments or issue references …

    line 22
  3. Very specific:

    Before classifying tests, read EVIDENCE.md in full.

    line 28
  4. Distinctive:

    DELETE: no meaningful protection beyond surviving tests.

    line 42
  5. Distinctive:

    Run the relevant tests after each group.

    line 54
  6. Distinctive:

    If a command fails, separate baseline failures from failures introduced by the group.

    line 56

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Test Value Audit

Triage every in-scope test as KEEP, MERGE, REWRITE, or DELETE. Preserve regression signal while reducing maintenance noise.

Modes

Use the tests, module, or suite named by the user as the audit boundary.

  • A review request produces findings only.
  • A cleanup request authorizes edits within that boundary.
  • Skill invocation without a cleanup request uses review mode.

Procedure

1. Establish the baseline

Read the in-scope tests, the production code they exercise, neighboring unit and integration tests, and any comments or issue references that explain regression history. Run the relevant test command before editing.

Complete this step when every in-scope test is mapped to its production behavior and neighboring coverage, and the baseline command and result are recorded.

2. Triage every test

Before classifying tests, read EVIDENCE.md in full. Apply its deletion gate, evidence patterns, seam checks, and protected-contract rules to every in-scope test.

For each test, identify:

  • The observable contract it protects.
  • A plausible regression it would detect.
  • Other tests that detect the same regression.
  • Its distinct diagnostic value.

Assign one decision:

  • KEEP: distinct, useful regression protection.
  • MERGE: useful protection spread redundantly across tests.
  • REWRITE: an important scenario that the current assertions do not protect.
  • DELETE: no meaningful protection beyond surviving tests.

Complete this step when every in-scope test has one decision and supporting evidence. Every DELETE decision must name a surviving replacement test by file and test name and explain which assertion detects the same regression. Classify unresolved contracts as requiring human judgment.

3. Apply authorized changes

In cleanup mode, change tests in small groups that have independent replacement coverage. Keep production code unchanged. Tests in the same deletion group cannot serve as replacements for one another.

Complete each group when every edit matches a triage decision and all named replacement tests remain in the suite.

4. Verify each group

Run the relevant tests after each group. Use available coverage tooling to inspect meaningful coverage changes, while treating executed lines as supporting data rather than replacement evidence.

If a command fails, separate baseline failures from failures introduced by the group. Repair or revert only the edits responsible for new failures before continuing.

Complete this step when every changed group has a recorded post-change result and no unresolved failure caused by the audit.

5. Report the audit

Report every in-scope test:

TestDecisionProtected behaviorValue evidenceSurviving replacementConfidence

For each deletion, include:

A regression that changes ___ would still be detected by ___ because ___.

Finish with totals for tests deleted, merged, rewritten, retained despite apparent overlap, and requiring human judgment. List commands and results, plus meaningful coverage changes.

Complete the audit when the table accounts for every in-scope test, every deletion names concrete surviving coverage, and all verification results are reported accurately.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.