Files
FabledGrimoire/plugin/skills/reviewing-tests/SKILL.md
T
bvandeusenandClaude Opus 5.5 70ca2e8a11
CI & Build / Python lint (push) Successful in 2s
CI & Build / Plugin hooks (push) Successful in 14s
CI & Build / TypeScript typecheck (push) Successful in 36s
CI & Build / Python tests (push) Successful in 2m15s
CI & Build / integration (push) Successful in 2m11s
CI & Build / Build & push image (push) Successful in 23s
feat(8248): the plugin ships a reviewing-tests skill: one verdict per test, deliberate breaks, every removal listed
The skill is the subtraction pass a suite never gets. It reviews against the
project's own test standard when one is recorded, takes before numbers from a
real run, works area by area with keep / merge / rewrite / move / remove,
records removals in the ledger (redundant with covered_by, unused) and kept
groups with review_test_group, breaks three to five protected behaviours per
area to prove the survivors fail, and lands each area as its own change.
It reaches work.verify. Plugin 2026.12.01.0344.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-30 22:44:18 -05:00

4.9 KiB

name, description, metadata
name description metadata
reviewing-tests Use when a test suite needs reviewing rather than growing — the operator asks to review, prune or tighten tests, CI is slow and the suite only ever grows, the coverage line counts test groups guarding the same thing or tests guarding nothing found, or a project's test standard asks for a review. Triggers on "review the tests", "prune the suite", "too many tests", "redundant tests", "CI is slow", "test standard". Gives each test one verdict, proves the survivors still fail, and lists every removal with its reason.
moments
work.verify

Reviewing a test suite

Every change adds tests and nothing removes them, so a suite left alone only grows: each test costs every CI run, forever, whether or not it still protects anything. A review is the subtraction pass. It gives every test one verdict, keeps the ones that earn their place, and leaves a record good enough that any removal can be argued back.

The standard comes from the project, not from this skill

Look for the project's own test standard first: a family idea it has adopted (enter_project lists ideas under family; get_family_adoption reads the project's answer), a rule, or a note — search for "test standard" in the project. Review against it, and use the test levels it names (unit, database, web, …) for "move" below. With no standard recorded, the verdicts below are the floor; agree the project's levels with the operator before moving any test, and offer to record them so the next review starts from them.

Before: the numbers you will compare against

Write these into the review's task before touching anything:

  • tests collected, from a real run's summary (not files, not a grep: a file that fails to collect reads exactly like a pass);
  • lines of test code;
  • CI time, from the last few green runs on the main working branch;
  • the coverage line's test figures: linked, guarding nothing found, redundant, and the number of groups guarding the same thing.

Area by area

Take one area at a time, the project's Systems or its test directories, and finish it before starting the next. In each area:

  1. Read what the ledger already knows. list_shapes(path=<area>) lists the test cases; a test status means the refresh linked it to something it guards, unclassified means it is linked to nothing. test_guard_groups lists tests in different files that guard exactly the same thing, each with its signals: signature (pins how code is declared), mock-only (asserts only that mocks were called), source-text (reads source as text). Signals point at what to read first; they never decide a verdict.
  2. Read every test and give it one verdict:
    • keep — it protects something a user or caller relies on, and nothing else in the suite protects it;
    • merge — it checks one case of a behaviour other tests also check: fold them into one table of cases;
    • rewrite — the subject is right and the check is weak: it pins a name, a signature or a mock call where it should pin an outcome;
    • move — it sits at a level the project's standard puts elsewhere;
    • remove — another test checks everything it checks (redundant, naming that test), or what it protects no longer matters to anyone (unused).
  3. Record the verdicts where they are kept. Removals go in the ledger: classify_shapes with status="redundant" and covered_by {path, symbol} for a test another covers, status="unused" for one nothing needs, a reason on each. A group judged to be distinct behaviours goes to review_test_group with what each test checks that the others don't. A test linked to nothing and kept says what it guards in an exempt reason.
  4. Break what the survivors claim to protect. Choose three to five behaviours the kept tests guard, break each one deliberately in the product code, and confirm the tests go red; then revert. Run them where the project's own rules say tests run. A test that stays green while its behaviour is broken protects nothing, whatever its name says: rewrite it or remove it.
  5. Land the area as one change that does nothing but this review, so it can be reverted alone. Behaviour changes found on the way are their own issues, never folded in.

After

  • Rerun the same numbers and put them beside the baseline in the review's task.
  • List every removed test with its verdict and reason, in that task's log. The list is what lets someone argue one back.
  • A test is never removed to make a red build green. A failing test is a finding about the code until a reading says otherwise.

Report

Lead with the numbers (tests, lines, CI time, before and after), then the removals by area with their reasons, then what the deliberate breaks proved and anything they caught. A test found guarding a real bug's absence that nobody knew about is the most valuable line in the report; say so plainly.