tdd

Guide Red-Green-Refactor cycles with test templates and recommended commands.

Updated Apr 28, 2026
One-click install
npx skills add https://github.com/suwandre/my-codex-config --skill tdd-suwandre
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tdd
Source: https://github.com/suwandre/my-codex-config/tree/main/skills/tdd
Command: npx skills add https://github.com/suwandre/my-codex-config --skill tdd-suwandre

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

TDD adoption is challenging without a clear, repeatable workflow and templates. This guide outlines the Red-Green-Refactor cycle and a practical process to write tests, run them, and refactor confidently.

Core Features & Use Cases

  • Red-Green-Refactor workflow: Step-by-step guidance to write a failing test, make it pass, and improve design.
  • Templates and usage patterns: Ready-to-use commands and a test-template to speed up test creation.
  • Process coverage: Clear instructions for starting sessions, running cycles, and maintaining code quality across features.

Quick Start

Initiate a TDD session for a feature and follow the Red-Green-Refactor cycle.

Frequently Asked Questions about tdd

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

FAQPage Schema
How do I start a test-driven development workflow for a new feature?

To start test-driven development for a new feature, you initiate a TDD session and follow the Red-Green-Refactor cycle by first writing a failing test, making it pass, and then refactoring the code to improve design.

What is the Red-Green-Refactor cycle in TDD?

The Red-Green-Refactor cycle in TDD is a development process where you write a failing test, implement the minimum code to make the test pass, and then refactor the implementation to improve code quality while maintaining passing tests.

How can I speed up test creation during feature development?

You can speed up test creation during feature development by using ready-to-use commands and a test template provided in the workflow, which helps standardize test generation and guide your refactoring decisions confidently.

What's the best way to maintain code quality while adopting TDD?

The best way to maintain code quality while adopting TDD is to follow clear process instructions for running cycles and refactoring decisions, ensuring you continuously improve the design after achieving passing tests without breaking functionality.

Does test-driven development work without external dependencies or testing frameworks?

Test-driven development workflows can be adopted without external dependencies by using built-in templates and commands to guide the process, though you still need a way to execute tests and verify the Red-Green-Refactor cycles.

Why is TDD adoption challenging without a repeatable workflow?

TDD adoption is challenging without a repeatable workflow because developers lack clear steps for test creation, running tests, and refactoring decisions, which leads to inconsistent feature development and reduced code quality confidence.