Test with confidence, code with clarity

Your home for mastering Test-Driven Development through real-world katas and expert guidance.

TDD Buddy Logo
Latest Scope Was Always a Test-Design Question

Kata Catalog

Practice TDD with a curated set of real-world katas, each with clear requirements and test cases.

Browse Katas

Guides & References

Learn best practices, naming conventions, and advanced TDD techniques from industry experts.

Explore Guides

Interactive Learning

Discover the TDD Gears model and learn how to apply TDD principles in real-world scenarios.

Learn More

Why TDD Matters More in the AI Era

The bar for "good tests" just moved. Agents made it non-optional.

  • Agents fail at scope at the same rate they fail at correctness. 33,580 agentic PRs, 2.66% carry a revert, and the top cause categories are co-equal: unintended side effects and overengineering at 22.33%, functional incorrectness at 22.13%. The failure mode is not only the fix; it is the stuff that came with the fix.
  • PR templates and diff-size caps catch at reading speed. A diff-size rule asks the reviewer to look at the diff. The reviewer still has to decide, PR by PR, whether a 400-line change should have been 40. The workflow catches a few, misses most, and runs at the author's speed, not the sampler's.
  • A scope assertion is a test on what must not change. An invariant test that names the behavior the PR is NOT supposed to touch (customer billing stays identical, order totals round the same way, the audit log keeps the same schema) is a test the sampler cannot author alongside the fix without noticing. The suite owns the scope the template was supposed to guard.
  • Scope is a design property of the suite, not a policy of the template. An instruction that says 'keep PRs small' is a request. A test that fails when the agent accidentally changes an unrelated billing invariant is a receipt. Structure wins over directive, and the suite is where the structure lives.

Read the argument: Scope Was Always a Test-Design Question

The Bar Moved

Old bar

Tests exist and pass. Good enough for humans with context.

New bar

Scenario names · builders · domain types · ubiquitous language. The test suite is the interface agents operate against.

TDD Gears

Shift gears based on context, not habit

TDD Gears model showing Low, Medium, High, and Reverse gears for test-driven development

Low Gear

New territory. Build context. Small steps. Learn the shape of the problem before solving it.

Medium Gear

Patterns emerge. Apply design principles. Let the tests guide you toward better abstractions.

High Gear

Known patterns. Follow existing architecture. Move fast because the structure is already proven.

Reverse Gear

Wrong direction. Back up. Delete the test. Try a different approach. This isn't failure — it's steering.