tdd

Drive feature work with red-green-refactor loops and public interface tests.

Updated Jul 20, 2026
One-click install
npx skills add https://github.com/brandtam/rubber-ducky --skill tdd-brandtam
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tdd
Source: https://github.com/brandtam/rubber-ducky/tree/main/.agents/skills/tdd
Command: npx skills add https://github.com/brandtam/rubber-ducky --skill tdd-brandtam

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Test-driven development helps teams ensure software behavior by writing tests before code, reducing regressions and rebuilding effort.

Core Features & Use Cases

  • Structure-driven development: write failing tests first to guide design, then implement just enough to pass.
  • Refactoring safety: ensure behavior remains stable while improving code structure.
  • Use Case: when adding or modifying features, drive implementation with a vertical slice of tests to validate public interfaces.

Quick Start

Describe a feature you want to add and start with a failing test to guide the implementation.

Frequently Asked Questions about tdd

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

FAQPage Schema
How does test-driven development improve software quality?

Test-driven development improves software quality by using failing tests to guide feature design, ensuring you implement only the minimal code required to pass. This reduces regressions and preserves behavior during refactoring.

How do I start adding a new feature using red-green-refactor?

To start adding a feature with red-green-refactor, describe the feature you want to build and write a failing integration-style test against its public interface first. Then, implement just enough code to pass that test before refactoring.

When should I use integration-style validation for test-driven development?

You should use integration-style validation for test-driven development when building or fixing features in a codebase that requires safe refactoring across projects. It ensures behavior remains stable while you improve code structure.

Can I safely refactor code without breaking existing behavior?

You can safely refactor code without breaking existing behavior by first driving implementation with a vertical slice of tests. These tests validate public interfaces and ensure structural improvements do not alter intended functionality.

Does test-driven development work for fixing existing features in a codebase?

Test-driven development works for fixing existing features by driving the implementation with a vertical slice of tests. You write tests against public interfaces first, implement minimal fixes to pass them, and refactor to stabilize structure.