/core:tddfrom core
Enforces framework-neutral TDD Red-Green-Refactor cycles: proves failing-before and passing-after tests, distinguishes valid RED from harness faults, and assesses refactoring while preserving existing test suites.
Ships in core. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Every line of new or changed behaviour must be written in response to a failing test.
This is non-negotiable: production code that adds or changes behaviour without a failing test demanding it is not TDD. Refactoring is the one exception: it changes structure while every test stays green, so it demands no new failing test.
Only an actual failing-before and passing-after behaviour test proves a RED/GREEN cycle. A build, typecheck or static page render does not replace it. Direct interaction with an identified running artifact and its observed effects is valid bounded runtime evidence, but does not retroactively prove TDD. Keep that evidence; if a fix preceded its test, reverse only your own fix, preserve unrelated work, and run the discriminating regression against pre-fix code before reapplying the minimal implementation. Report the command, result and what it proves at each transition (principle-prove-it-works).
Use the project's existing runner and test framework across web, iOS, CLI,
library and service projects. Retain existing XCTest suites, including measure
performance tests; TDD does not require migration to Swift Testing. Framework
authoring belongs to the matching skill or the suite's established conventions.
Treat coverage as a by-product of the required behaviour cases, not a separate coverage-only task. Use a coverage report to discover missing business cases; never add implementation-detail assertions merely to satisfy a percentage.
Write one test that describes the desired behaviour. Run it against the pre-change production code. The test must fail because the behaviour does not exist yet.
A failure that names the absent unit under test is a valid RED: an unresolved import of the module you are about to create, an undefined export you are about to add, or a wrong, missing, or thrown result from the code under test.
Any other failure is a harness fault, not RED: a wrong import path, a typo in the test file, a missing dependency, a broken runner configuration, or a compile error in unrelated code. Repair the harness fault first, preserving unrelated work and every existing test. Rerun the test before you write production code.
Never duplicate an existing test.
Rules:
principle-preserve-unrelated-work).principle-test-behavior-not-implementation).Write the minimum code to make the current test pass. Nothing more.
Rules:
principle-foundational-thinking).principle-scale-verification).After every GREEN, assess whether refactoring would add value: once per behaviour, not once after a batch. If the code is already clean, move on. The refactoring skill owns the full procedure; these rules apply in every cycle:
principle-capture-the-baseline).| Guide | Use for |
|---|---|
| workflow-examples.md | Full RED-GREEN-REFACTOR walkthroughs (free shipping, payment validation); when to refactor vs move on |
| test-factories.md | Factory functions with overrides, why they beat let/beforeEach, composing factories, organising tests by behaviour, no 1:1 test-to-implementation mapping, 100% coverage through behaviour |
| violations.md | Critical violations, high-priority issues, style issues, behaviour vs implementation examples |
| patterns.md | Behaviour-focused tests, public-API-only testing, factories with schema validation, composing factories, test naming and organisation |
Does this code add or change behavior?
├── No (pure refactor under green tests) → Keep every test green
└── Yes → Is there a failing test demanding it?
├── Yes → Write minimal code to pass
└── No → Write the failing test first
Does the test verify a business outcome?
├── Yes → Does it use the public API only?
│ ├── Yes → Is its test data fresh and explicit?
│ │ ├── Yes (JS/TS factories; simple local immutable Swift values also qualify) → Good test ✓
│ │ └── No → Use factories in JS/TS; remove shared mutable fixtures
│ └── No → Rewrite to avoid internals
└── No → Rewrite to focus on behavior
Does this code make the current failing test pass?
├── Yes → Is there any code that could be removed
│ and tests still pass?
│ ├── Yes → Remove it
│ └── No → Done
└── No → Keep writing minimal code
let declarations or beforeEach builders. Local immutable Swift let bindings are valid. Keep legitimate resource lifecycle hooks.What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub mintuz/skills --plugin core37 skills in this plugin
/acceptance-reviewWHEN deciding whether a PR, branch, diff, or current code satisfies an authoritative issue, specification, or decision contract; NOT for reconstructing meetings, tracing decision lineage, general code review, or implementation; returns a criterion-by-criterion proof and acceptance verdict./adam-modeWHEN explicitly invoked as /adam-mode or asked to work in Adam's style; NOT for automatic invocation; routes the task to a playbook, loads the principle and domain skills it needs, delegates through adam-agent and proves the result before it reports./architectWHEN shaping non-trivial code whose types, signatures, non-type contracts or module boundaries are not settled, before implementation; NOT for edits inside one function, read-only explanation, repo-wide hotspot scans, physical folder/package layout, or work whose design is already agreed; sketches caller usage, types, dependencies and module boundaries through arena, then implements against the agreed sketch when authorisedOther plugins' skills for the same job