tdd-workflow

Define and enforce a Test-Driven Development workflow with RED-GREEN-REFACTOR phases.

Updated Mar 27, 2026
One-click install
npx skills add https://github.com/minhquan2904/vibe-check-scam --skill tdd-workflow-minhquan2904
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tdd-workflow
Source: https://github.com/minhquan2904/vibe-check-scam/tree/main/base_knowledge/standards/base/tdd-workflow
Command: npx skills add https://github.com/minhquan2904/vibe-check-scam --skill tdd-workflow-minhquan2904

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Test-Driven Development workflow principles guide teams to write tests before code, reducing defects and ensuring a repeatable development rhythm.

Core Features & Use Cases

  • The RED-GREEN-REFACTOR cycle to structure development and improve design
  • Clear rules for writing effective tests and maintaining confidence in refactors
  • AAA testing pattern to organize tests for readability and maintainability

Quick Start

Write a failing unit test first, then implement the minimal code to pass and refactor.

Frequently Asked Questions about tdd-workflow

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

FAQPage Schema
What is the red-green-refactor cycle in test-driven development?

The red-green-refactor cycle in test-driven development structures feature work by first writing a failing test (RED), implementing minimal code to pass it (GREEN), and then improving the design without changing behavior (REFACTOR). This ensures repeatable, high-quality outcomes and reduces defects.

How do I structure unit tests for better readability and maintainability?

To structure unit tests for readability and maintainability, apply the AAA testing pattern. The AAA pattern organizes tests into three distinct phases: Arrange the preconditions, Act on the system under test, and Assert the expected outcomes.

How do I start writing tests before code in a feature development cycle?

To start writing tests before code in a feature development cycle, follow the test-driven development workflow: write a failing unit test first, implement the minimal code required to make that test pass, and then refactor the implementation while maintaining test confidence.

Does test-driven development work for software teams without an existing test suite?

Yes, test-driven development works for software teams without an existing test suite. The workflow applies directly to new feature development cycles by establishing a rhythm of writing unit tests first, ensuring repeatable high-quality outcomes from the start.

Why does refactoring break existing unit tests and how can I maintain confidence?

Refactoring may break existing unit tests if the internal design changes without updating test expectations. To maintain confidence during refactors, follow clear rules for writing effective tests and ensure the test suite covers the expected behavior through the AAA pattern.