cf-test
Skill1 starsChanged 27 days agoMITView on GitHub
Report assertion-quality findings for pending tests, a named history range, explicit tests, or the existing suite. Use when the request asks to review assertion quality, coverage against invariants, brittle or over-specified tests, flaky or nondeterministic tests, implementation-detail coupling, negative assertions, or invalid domain states representable by the project's types or schemas. Route ambiguous expected behavior to cf-mr-wolf.
In this repository10 other files it gives its agents.
- AGENTS.mdAGENTS.md
- cf-architectureSkill
- cf-brainstormSkill
- cf-cleanSkill
- cf-cognitiveSkill
- cf-deadcodeSkill
- cf-docsSkill
- cf-mr-wolfSkill
- cf-placementSkill
- cf-scenarioSkill
The file
We split this skill into the rules it gives an agent
6 rules. About 0 are common, 2 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 22
No invariant or observable contract, no candidate.
- Very specific: line 28
Read references/context-gate.md.
- Very specific: line 29
Read references/assertion-quality.md and run every declared lens group.
- Distinctive: line 36
When it already exists and the request is about it, work through it under the same contract instead of running the Flow.
- Very specific: line 37
Create or update no other repository file, including any other .cflow/* file and todo files.
- Very specific: line 45
Lenses: every lens from references/assertion-quality.md, marked reporting, silent, or not applicable with the absent condition.
≈ “Common” is an estimate: at least 1 in 5 of the 408,460 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.
Files
Report assertion-quality candidates against observable contracts and invariants. Do not edit repository files other than the batched pass's recap, or turn test style preferences into candidates.
Scope
Resolve exactly one test scope:
- Pending tests, the default when no target is named and the working tree holds test changes: existing test files selected by staged, unstaged, and untracked work together.
- The existing suite, when no target is named and the working tree holds no test change: every existing test file. A clean checkout does not make a request about tests unanswerable; it makes the whole suite the subject.
- A named history range: existing test files selected by the requested commits, range, or branch.
- Explicit tests: the named test files or directories, whether changed or unchanged.
Treat every selected test file as a primary test and inspect it as a whole. Treat changed production files in the same change set, production files directly imported by explicit tests, and identified authoritative sources as contract surfaces. Requirements, product or domain documentation, and acceptance criteria are authoritative sources only when they name the tested behavior; path proximity alone is insufficient. Contract surfaces provide evidence but are not themselves review targets.
Exclude generated, vendored, ignored, fixture-only, snapshot-output, and deleted files unless an authoritative source makes one directly relevant.
Hard Gates
- No invariant or observable contract, no candidate. A preference is not an invariant.
- Report one candidate per test case or test table, or per duplicated setup with its copies. Do not turn one candidate into a repository-wide pattern inventory.
Flow
- Resolve primary tests, contract surfaces, and authoritative sources by path without loading the corpus in full.
- Read
references/context-gate.md. Run the installed-local context gate against every primary test and already-selected contract surface. Follow its policy exactly; when it isbatched, readreferences/batched-execution.mdand follow it. - Read
references/assertion-quality.mdand run every declared lens group. Forlocal, run them sequentially. Forbatched, every batch applies every lens group. The shared reference owns batching and completion. - De-risk every candidate against the cited primary test, contract surface, and authoritative source. Inspect only the cited evidence needed to accept, narrow, or exclude it.
- Route once after the complete pass. Route ambiguous expected behavior, and a domain-model redesign such as making invalid domain states unrepresentable, to
cf-mr-wolf.
Artifacts
- Owns
.cflow/cf-test-recap.md: the batched pass's recap, written under the Recap File contract inreferences/batched-execution.md. It is the pass's one repository write. - When it already exists and the request is about it, work through it under the same contract instead of running the Flow.
- Create or update no other repository file, including any other
.cflow/*file and todo files. Persisting candidates in a todo file belongs tocf-docs.
Output Format
Return only:
- Scope: resolved scope, primary tests, contract surfaces, authoritative sources, and exclusions.
- Context budget: measured files, LOC, estimated tokens, and selected policy.
- Lenses: every lens from
references/assertion-quality.md, marked reporting, silent, or not applicable with the absent condition. - Findings: candidates grouped by the action their lens names, in the order
remove,rewrite,strengthen,redesign, and by severity within each group. A test case that does not pay for itself is the answer to a different question than a test case that covers too little, and burying the first under the second answers neither. Each candidate carries id, primary test, claim, evidence, invariant or observable contract, concrete regression or behavior-preserving change, severity, confidence with its basis, false-positive check, route (cf-mr-wolfornone), statuscandidate, and unknowns. - Handoff: destination mapped to candidate ids, recommended first action, or
none. - Result:
clearorcandidates found, opening with how many test cases are proposed forremove; then state that confirmation is still needed, that no files were modified except the recap when written, and the next action.
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
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.

