tdd

Enforce test-first development with red-green-refactor cycles and npm test.

28|5|Updated Jan 26, 2026
One-click install
npx skills add https://github.com/MeroZemory/oh-my-droid --skill tdd-merozemory
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: tdd
Source: https://github.com/MeroZemory/oh-my-droid/tree/main/skills/tdd
Command: npx skills add https://github.com/MeroZemory/oh-my-droid --skill tdd-merozemory

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Ensures no production behavior is delivered before a failing test exists so that every implementation remains accountable to verifiable expectations and the code base stays safe from regression.

Core Features & Use Cases

  • Iron Law Enforcement: Rejects any attempt to write functionality before a failing test by instructing the developer to delete premature code and craft the test first.
  • Red-Green-Refactor Discipline: Documents the step-by-step cycle—write a failing test, implement the minimal passing code, and refactor while continuously running npm test to keep the suite green.
  • Use Case: When adding a new API endpoint, follow the skill to start with a failing test, lock in the minimal implementation, then clean up while confirming every npm test run still passes.

Quick Start

Ask the AI to guide you through the next red-green-refactor cycle for the feature you want to implement.

Frequently Asked Questions about tdd

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I enforce test-driven development practices in my engineering workflow?▼

Test-driven development is enforced by rejecting any implementation code written before a failing test exists, requiring developers to delete premature code and craft the test first to ensure accountability and prevent regressions.

What is the red-green-refactor cycle and how do I apply it?▼

The red-green-refactor cycle involves writing a failing test, implementing the minimal passing code, and refactoring while continuously running npm test to keep the suite green and verify no extra functionality slips through.

How do I start adding a new API endpoint using strict test-first development?▼

Start adding a new API endpoint by writing a failing test that defines the expected behavior, implement the minimal code to pass it, then clean up the implementation while confirming every npm test run still passes.

Can I use this to prevent untested production behavior from being merged?▼

Yes, it prevents untested production behavior by enforcing strict test-first development, ensuring no production behavior is delivered before a failing test exists so the code base stays safe from regression.

What happens if I write functionality before writing a failing test?▼

If functionality is written before a failing test, the enforcement mechanism rejects the attempt by instructing the developer to delete the premature code and craft the required test first.

Do I need npm test to verify my code during the refactor phase?▼

Yes, you need npm test to verify code during the refactor phase, as continuous test runs are required to confirm the suite stays green and no extra functionality slips through to production.