lackeyjb/claude-conductor/tdd-workflow
- community
Checking that the SKILL.md file is still in the repository.
Test-Driven Development guidance. Use when writing code, implementing features, or fixing bugs in projects that follow TDD methodology. Provides the Red-Green-Refactor cycle structure.
Install
npx vskill@latest install lackeyjb/claude-conductor/tdd-workflowSKILL.md
TDD Workflow Skill
Guidance for Test-Driven Development methodology.
The Core Cycle
RED → GREEN → REFACTOR (repeat)
| Phase | Purpose | Actions | Verify | |
|---|---|---|---|---|
| RED | Define expected behavior | Write test for ONE behavior, run test | Test FAILS | |
| GREEN | Make it work | Write MINIMUM code to pass | Test PASSES | |
| REFACTOR | Make it clean | Improve ONE thing at a time, run tests after each change | Tests stay GREEN |
Phase 1: RED - Write Failing Test
Purpose: Define behavior before implementation.
Actions:
- Create/open test file
- Write test for ONE behavior
- Run test
- Verify FAILURE (if it passes, test is wrong)
Common mistakes: Tests pass immediately, testing implementation not behavior, writing too many tests at once
Phase 2: GREEN - Make It Pass
Purpose: Write MINIMUM code to pass test.
Actions:
- Implement just enough to pass
- No extra features, no optimization
- Run tests, verify PASS
Common mistakes: Over-engineering, adding untested features, "while I'm here" additions
Phase 3: REFACTOR - Improve Quality
Purpose: Clean up while keeping tests green.
Actions:
- Identify improvements: duplication, naming, complex logic, long functions
- Make ONE change
- Run tests
- If green, continue. If red, undo.
Checklist: Extract methods, rename variables, remove duplication (DRY), simplify conditionals, add type safety
Test Patterns
Arrange-Act-Assert (AAA):
- Arrange: Set up test data
- Act: Execute the behavior
- Assert: Verify result
Given-When-Then (BDD): Structure nested describes for readability
Coverage Commands
| Language | Command | |
|---|---|---|
| JS/TS (Jest) | npx jest --coverage | |
| JS/TS (Vitest) | npx vitest run --coverage | |
| Python | pytest --cov=src --cov-report=html | |
| Go | go test -cover ./... |
Anti-Patterns to Avoid
- Test After: Writing code first defeats TDD purpose
- Testing Implementation: Test WHAT it does, not HOW (test behavior, not internal calls)
- Brittle Tests: Use resilient assertions (e.g.,
toContainEqualnot array index checks) - No Refactoring: Skipping refactor creates technical debt
Quick Reference
- RED: "What should it do?" → Write failing test
- GREEN: "Does it work?" → Write minimal code
- REFACTOR: "Is it clean?" → Improve structure
For detailed code examples, see examples.md in this skill directory.
Integration
Works with:
- context-awareness: Project-specific coverage targets
- code-styleguides: Language-specific test patterns
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/tdd-workflow/SKILL.md
Popularity
- 7-day trend score
- 5
Not refreshed yet.
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/lackeyjb/claude-conductor/tdd-workflow)