Back to library

🔴TDD Workflow Explained

Stop hearing 'red-green-refactor' as a slogan and start feeling it as a five-minute rhythm — drill ten kata cycles, connect TDD to design and coverage, then build a small feature strictly test-first.

Foundations14 drops~2-week path · 5–8 min/daytechnology

Phase 1Why the Cycle Works

See TDD as a feedback rhythm, not a slogan

4 drops
  1. TDD is a rhythm, not a religion

    6 min

    TDD is a rhythm, not a religion

  2. A failing test is the only honest starting point

    6 min

    A failing test is the only honest starting point

  3. Green means smallest possible code, not best

    6 min

    Green means smallest possible code, not best

  4. Refactor is where the design actually happens

    7 min

    Refactor is where the design actually happens

Phase 2Ten Laps Around the Cycle

Drill ten kata cycles at the right granularity

5 drops
  1. FizzBuzz is a TDD treadmill, not a puzzle

    7 min

    FizzBuzz is a TDD treadmill, not a puzzle

  2. If red lasts more than five minutes, your test is too big

    7 min

    If red lasts more than five minutes, your test is too big

  3. The second test is what makes the design real

    6 min

    The second test is what makes the design real

  4. When red won't go green, throw the test away

    6 min

    When red won't go green, throw the test away

  5. Don't write code with no failing test

    6 min

    Don't write code with no failing test

Phase 3The Cycle Meets Real Code

Connect TDD to design, coverage, and refactoring

4 drops
  1. TDD applies design pressure on every lap

    7 min

    TDD applies design pressure on every lap

  2. 100% coverage means nothing if your tests can't fail

    7 min

    100% coverage means nothing if your tests can't fail

  3. On legacy code, write the test that pins behavior

    7 min

    On legacy code, write the test that pins behavior

  4. TDD is a tool, not a religion — know when to skip it

    7 min

    TDD is a tool, not a religion — know when to skip it

Phase 4Build It Test-First

Build a small feature strictly test-first

1 drop
  1. Ship a small feature, strictly test-first

    25 min

    Ship a small feature, strictly test-first

Frequently asked questions

What does red-green-refactor actually mean in practice?
This is covered in the “TDD Workflow Explained” learning path. Start with daily 5-minute micro-lessons that build from fundamentals to hands-on application.
Isn't TDD slower than just writing code and tests after?
This is covered in the “TDD Workflow Explained” learning path. Start with daily 5-minute micro-lessons that build from fundamentals to hands-on application.
How small should the first failing test be?
This is covered in the “TDD Workflow Explained” learning path. Start with daily 5-minute micro-lessons that build from fundamentals to hands-on application.
Do I need 100% coverage if I'm doing TDD?
This is covered in the “TDD Workflow Explained” learning path. Start with daily 5-minute micro-lessons that build from fundamentals to hands-on application.
When is it okay to skip TDD on a real project?
This is covered in the “TDD Workflow Explained” learning path. Start with daily 5-minute micro-lessons that build from fundamentals to hands-on application.