Skill
Test-Driven Development
The core build loop: red-green-refactor with node:test until every requirement passes.
// workflow;Behaviour
What it does
- Writes a failing node:test before any production code
- Names tests with REQ-IDs for traceability (e.g. REQ-042-AC1)
- Confirms the failure message matches the requirement
- Writes the minimal code to pass, then refactors while staying green
- Never weakens a test to force green; fixes the code instead
- Covers unit tests beside source and functional tests in test/
- Loops until the requirement is fully covered
When to use
Good fits
During executing-plans, for each implementation task
When you want disciplined red-green-refactor, not vibe coding
For any feature work where tests should drive the design
Development harness
Inner loop
Part of the design-to-ship pipeline: brainstorming → technical-documentation → conformance-check → reconciling-changes → planning → project-setup → executing-plans → shipping. Install the full set for structured feature work.
Used inside executing-plans as the inner red-green-refactor loop for each task.
Install
Get this skill
Uses Agent Kit via npx; no global install required.
Quick install
sh
npx @levi-putna/agent-kit@latest add levi-putna/skills --skill test-driven-developmentGlobal (Cursor)
sh
npx @levi-putna/agent-kit@latest add levi-putna/skills --skill test-driven-development --global --agent cursorGlobal (Claude)
sh
npx @levi-putna/agent-kit@latest add levi-putna/skills --skill test-driven-development --global --agent claudeProject install
sh
npx @levi-putna/agent-kit@latest add levi-putna/skills --skill test-driven-development --projectInteractive install
sh
npx @levi-putna/agent-kit@latest add levi-putna/skillsUninstall
sh
npx @levi-putna/agent-kit@latest remove test-driven-developmentExample
Example prompt
Test-Driven Development
Implement the cart total requirement with TDD. Watch the test fail first.
Flow
How the skill works
- Write a failing test for one requirement
- Run node:test and confirm it fails for the right reason
- Write minimal code to pass
- Refactor while keeping tests green
- Repeat until the requirement is done