docs(guides): add TDD workflow + restructure adding-a-feature for TDD order

New: docs/guides/tdd-workflow.md — red-green-refactor cycle, AAA,
mocking decision tree, coverage targets, factory + contract usage.
Restructured: adding-a-feature.md interleaves tests with implementation;
TDD order is required, not optional. testing-strategy.md cross-links
the new guide. AGENTS.md and CLAUDE.md surface both.

Spec: §7

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-05 19:28:00 +02:00
parent bd50a67662
commit 17d3488fb4
5 changed files with 1268 additions and 208 deletions

View File

@@ -2,6 +2,8 @@
A layered approach: per-feature DI containers + colocated unit tests + Playwright e2e.
For the *how* of TDD (red-green-refactor cycle, when to mock, what NOT to test), see [tdd-workflow.md](./tdd-workflow.md). This document covers test *placement* and infrastructure.
## Test placement
| Level | Location | Tool | Example |