tdd

Guide teams to write failing tests before implementing code.

11|5|Updated Jan 9, 2026
One-click install
npx skills add https://github.com/rbergman/dark-matter-marketplace --skill tdd-rbergman
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tdd
Source: https://github.com/rbergman/dark-matter-marketplace/tree/main/plugins/workflow/skills/tdd
Command: npx skills add https://github.com/rbergman/dark-matter-marketplace --skill tdd-rbergman

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill promotes test-first development, guiding teams to write a failing test before implementing code to ensure correct behavior from the start.

Core Features & Use Cases

  • Red-Green-Refactor workflow: write a failing test, implement minimal code, then refactor while keeping tests green.
  • Shift-left quality assurance: applies to new features, bug fixes, and refactors to verify behavior with automated tests.
  • Real-world use case: when starting a feature, author a focused test that captures expected behavior prior to coding.

Quick Start

Start by writing a failing test for the desired behavior, implement the minimal code to pass it, and refactor while keeping tests green.

Frequently Asked Questions about tdd

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

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

Test-first development requires writing a failing test for expected behavior before implementing code. The red-green-refactor workflow involves writing a failing test, implementing minimal code to pass it, then refactoring while keeping tests green.

How do I start writing unit tests for a new feature before coding?

Start writing unit tests by authoring a focused test that captures the expected behavior of the feature prior to coding. Implement the minimal code required to make the test pass, ensuring correct behavior from the start.

Can I apply test-first development to bug fixes and refactoring across different languages?

Test-first development applies to feature work, bug fixes, and refactors across languages and project types. It requires only standard test frameworks to verify behavior with automated tests without introducing additional tooling.

Does test-driven development require specific testing frameworks or complex tooling?

Test-driven development requires only standard test frameworks and promotes a minimal red-green-refactor workflow without introducing tooling or complexity. It ensures behavior is verified by tests using existing project frameworks.

Why should I write a failing test before implementing code?

Writing a failing test before implementing code catches bugs early and ensures correct behavior from the start. This shift-left quality assurance approach verifies behavior with automated tests throughout feature work, bug fixes, and refactors.