compound-v-tdd

Enforce tests-first development with red/green/refactor cycles.

Updated Feb 7, 2026
One-click install
npx skills add https://github.com/shermanhuman/promptherder --skill compound-v-tdd
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: compound-v-tdd
Source: https://github.com/shermanhuman/promptherder/tree/main/compound-v/skills/compound-v-tdd
Command: npx skills add https://github.com/shermanhuman/promptherder --skill compound-v-tdd

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill enforces tests-first development by applying red/green/refactor discipline to feature work, bug fixes, and refactoring, ensuring that behavior is validated by tests from the start.

Core Features & Use Cases

  • Tests-first workflow: guide teams to write failing tests before implementing code and to iterate with red, green, and refactor cycles.
  • Regression testing emphasis: ensures new changes are guarded by regression tests to prevent reintroducing bugs.
  • Use Case: during a feature add or bug fix, you create or adjust tests first, then implement the minimal code to satisfy them.

Quick Start

Define a failing test for the intended behavior, implement the minimal code to pass, and then refactor while keeping all tests green.

Frequently Asked Questions about compound-v-tdd

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

FAQPage Schema
How do I enforce a tests-first workflow for new features and bug fixes?

The red-green-refactor cycle starts with writing a failing test for intended behavior, then implementing minimal code to make it pass, and finally refactoring while keeping all tests green to ensure software quality.

How do I prevent bug reintroduction when refactoring code?

To prevent bug reintroduction, you emphasize regression testing by guarding new changes with explicit tests. This ensures any fixes or refactoring are verifiable by the test suite and prevents reintroducing bugs.

Can I use test-driven development for both feature work and refactoring?

Yes, you can apply test-driven development to feature work, bug fixes, and refactoring. It anchors all code changes to explicit test requirements, ensuring changes are verifiable by the test suite across all development activities.

What is the best way to start a test-driven development cycle?

The best way to start is to define a failing test for the intended behavior. After the test fails, implement the minimal code required to satisfy the test requirements, and then refactor while keeping all tests green.

Why does test-driven development require writing failing tests first?

Test-driven development requires writing failing tests first to anchor code changes to explicit test requirements. This validates expected behavior from the start and ensures the implementation is verifiable by the test suite.