TDD First: Test-Driven Development is the default approach.
Goal: Prioritize behavioral correctness and regression safety over formal compliance.
Workflow
Requirement Synthesis: Briefly summarize the requirements before coding.
Test Specification: Write tests describing the expected behavior (unit, integration, or E2E).
Implementation: Update the logic only to the extent required to satisfy those tests.
Mandatory Rules
No Test, No Code: Every new feature or bugfix must include relevant test coverage.
Black-Box Testing: Validate observable behavior, not internal implementation details.
Merge Requirement: Tests are mandatory for completion unless an explicit exception is documented.
Preferred Practice
Red-Green-Refactor: Start with a failing test whenever practical.
Right-Sized Testing:
Unit Tests: For pure logic and isolated functions.
Integration Tests: For system interactions and API boundaries.
E2E Tests: For critical user journeys and "happy paths."
Explicit Exceptions (Must be justified)
Pure refactoring (where behavior remains identical).
Exploratory spikes or R&D.
UI/Styling iterations where unit tests offer diminishing returns.
Complex integrations where mocking is counterproductive.
Emergency hotfixes (requires a follow-up ticket for test debt).
Quality Bar
Readability: Tests must serve as documentation for the feature.
Reliability: Tests must be deterministic (no flakes) and decoupled from implementation internals.
Converted and distributed by TomeVault — claim your Tome and manage your conversions.
1---2name: tdd-213description: Apply Test-Driven Development workflow for new features and bugfixes. Use when this capability is needed.4---56# TDD Protocol78## Core Principle910- **TDD First**: Test-Driven Development is the default approach.11- **Goal**: Prioritize behavioral correctness and regression safety over formal compliance.1213## Workflow14151. **Requirement Synthesis**: Briefly summarize the requirements before coding.162. **Test Specification**: Write tests describing the expected behavior (unit, integration, or E2E).173. **Implementation**: Update the logic only to the extent required to satisfy those tests.1819## Mandatory Rules2021- **No Test, No Code**: Every new feature or bugfix must include relevant test coverage.22- **Black-Box Testing**: Validate observable behavior, not internal implementation details.23- **Merge Requirement**: Tests are mandatory for completion unless an explicit exception is documented.2425## Preferred Practice2627- **Red-Green-Refactor**: Start with a failing test whenever practical.28- **Right-Sized Testing**:29 - **Unit Tests**: For pure logic and isolated functions.30 - **Integration Tests**: For system interactions and API boundaries.31 - **E2E Tests**: For critical user journeys and "happy paths."3233## Explicit Exceptions (Must be justified)3435- Pure refactoring (where behavior remains identical).36- Exploratory spikes or R&D.37- UI/Styling iterations where unit tests offer diminishing returns.38- Complex integrations where mocking is counterproductive.39- Emergency hotfixes (requires a follow-up ticket for test debt).4041## Quality Bar4243- **Readability**: Tests must serve as documentation for the feature.44- **Reliability**: Tests must be deterministic (no flakes) and decoupled from implementation internals.4546---47> Converted and distributed by [TomeVault](https://tomevault.io/claim/smartfrog) — claim your Tome and manage your conversions.48<!-- tomevault:4.0:skill_md:2026-04-11 -->
Run npx get-skill add tomevault-io/tdd-21 in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
Apply Test-Driven Development workflow for new features and bugfixes. Use when this capability is needed. It is listed under Productivity on SkillMD.
This skill has not completed SkillMD's automated safety review yet. Independent scanners report: SkillSpector: PASS, Skill Scanner: PASS. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Yes. Installing skills from SkillMD is free, and the skill stays under its author's original license.
tomevault-io (@tomevault-io) published this skill. Their other Agent Skills are listed on their SkillMD profile.