acedergren/agentic-tools/tdd
Claude Code and agent skill by acedergren/agentic-tools
- community
Checking that the SKILL.md file is still in the repository.
Use when implementing features, fixing bugs, or adding deliberate test coverage. Enforces test-first (red-green-refactor) cycle, handles mock bootstrap for projects with mockReset:true, prevents code-before-tests violations. NOT for reviewing existing code or running test suites. Triggers on "write test first" or "use TDD".
Install
npx vskill@latest install acedergren/agentic-tools/tddSKILL.md
TDD Implementation Skill
When to Use
Load this skill when the user request matches the frontmatter description for TDD Implementation Skill.
Enforce a strict test-driven development cycle: Red → Green → Refactor → Commit.
NEVER
- NEVER write implementation before tests — this is the entire point; skip it and the skill has no value
- NEVER skip mock bootstrap validation — write one mock round-trip test first and confirm it passes before writing 20 tests
- NEVER skip the full test suite run — your file passing is not enough; regressions in unrelated files are your responsibility to notice
- NEVER proceed if tests pass in Red phase — a test that passes before implementation is testing nothing; revise it
- NEVER batch multiple features into one TDD cycle — one behavior change per red-green-refactor loop
- NEVER treat a compile/import error as "red" — tests must fail for the right reason (assertion failure, not broken setup)
Before Writing Any Tests
If `mockReset: true` in test runner config, most internet mock examples silently fail — return values clear between tests.
If mockReset: true, you MUST reconfigure return values in beforeEach, not at module scope. Write ONE bootstrap test first to validate your mock wiring:
Run it, confirm it passes, then delete it and write the real tests using that same pattern.
Red Phase
Write tests covering: happy path, edge cases (empty/boundary inputs), error cases (invalid input, unauthorized, missing resource).
Checkpoint: All new tests MUST fail. If any pass → the behavior already exists or the test is wrong.
Green Phase
Write the minimum code to make tests pass. No untested features, no premature optimization, no untested error handling.
Checkpoint: All tests (new and existing) pass.
Full Suite
If outside tests fail: determine if your change caused the regression. If yes → fix before proceeding. If pre-existing → note it and continue.
Refactor (Optional)
Only when tests are green. Extract helpers, improve naming, simplify conditionals. Re-run full suite after.
Quality Gates
Fix before committing.
Mock Patterns Reference
Forwarding Pattern (survives mockReset)
Counter-Based Sequencing (multi-query operations)
globalThis Registry (TDZ workaround for interdependent mocks)
Arguments
$ARGUMENTS: Optional description of what to implement via TDD- Example:
/tdd add rate limiting to the search endpoint - If empty: ask the user what to implement
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/tdd/SKILL.md
Popularity
- Repository stars
- 12
- Repository forks
- 2
- 7-day trend score
- 13
Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 7 May 2026, 6 months ago.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/acedergren/agentic-tools/tdd)