2. Test Immutability Contract
- Test Integrity: Implementation agents must NEVER modify or delete existing test assertions. If an implementation agent cannot pass a test, it must fix the implementation, not loosen the test.
- Contract Changes: Alterations to existing tests require explicit user confirmation.
3. Test Stratification & Isolation
- Frozen Contract Tests (
tests/spec/): Immutable behavioral specifications that define acceptance criteria. - Mutable Integration Tests (
tests/integration/): Dynamic end-to-end tests validating multi-module interactions. - Directory Placement: All test suites reside strictly in a top-level
tests/directory; never co-locate tests inside source code directories. - Golden Fixtures: Share single, authoritative golden fixture files across modules that exchange identical data schemas.