One-click install
npx skills add https://github.com/Hebilicious/wrangler-builds --skill tdd-hebilicious
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tdd
Source: https://github.com/Hebilicious/wrangler-builds/tree/main/.agents/skills/tdd
Command: npx skills add https://github.com/Hebilicious/wrangler-builds --skill tdd-hebilicious

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Teams often build features without a disciplined feedback loop, leading to fragile code and missed requirements. This skill provides a clear workflow for adopting Test-Driven Development (TDD) using red-green-refactor cycles to guide design and ensure public behavior is validated by tests.

Core Features & Use Cases

  • Planning with tracer bullets: Define one observable behavior, write a failing test, and implement just enough code to pass.
  • Vertical slices over horizontal work: Focus on end-to-end functionality through small, testable increments.
  • Safe refactoring guardrails: Use refactor steps after each passing test to improve design without changing observable behavior.
  • Educational guidance: Includes anti-patterns and best practices to help teams learn TDD in real projects.

Quick Start

Identify a single observable behavior, write a failing test, then implement just enough code to make it pass.

Frequently Asked Questions about tdd

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

FAQPage Schema
What is test-driven development and how does the red-green-refactor loop work?

Test-driven development (TDD) is a workflow where you write a failing test, implement just enough code to pass it, then refactor safely. The red-green-refactor loop validates public behavior incrementally to ensure reliable features.

How do I plan features using tracer bullets in TDD?

Planning with tracer bullets in TDD involves defining one observable behavior, writing a failing test for it, and implementing minimal code to pass. This builds vertical slices of end-to-end functionality through small, testable increments.

How do I refactor code safely without changing observable behavior during TDD?

To refactor safely during TDD, execute refactor steps only after a test passes. This improves internal design while maintaining validated public behavior, preventing fragile code and missed requirements.

When should I use vertical slices instead of horizontal layers for feature development?

Use vertical slices over horizontal work when building features with TDD to focus on end-to-end functionality. This approach ensures each increment is testable and delivers observable behavior validated by tests.

Can I use test-driven development for bug fixes and learning environments?

Yes, TDD applies to bug fixes and learning environments by practicing the red-green-refactor loop. It provides structured workflows, anti-patterns, and best practices to help teams learn test-driven development in real projects.

Why does building features without a feedback loop lead to fragile code?

Building features without a disciplined feedback loop leads to fragile code because requirements are missed without test validation. TDD solves this by using red-green-refactor cycles to guide design and ensure public behavior is validated.