pa-10 — Verification

One command

cd pa-10-architecture-in-practice && bash scripts/verify.sh

What the tests prove

TestInvariant
TestNoCyclesPassesAndFailsacyclic passes; a cycle is detected
TestLayeringRulea forbidden layer dependency is flagged
TestMaxFanOutexceeding the coupling budget is flagged; within it passes
TestEvaluateAggregatesAndGatesCIan unhealthy architecture fails the aggregate gate with named violations
TestCleanArchitecturePassesa dependency-inverted, acyclic, low-coupling design passes all rules

All under -race. Wire Evaluate into a real TestArchitecture and the build fails when the architecture regresses.

What "green" does NOT guarantee

  • Objective rules, not wisdom. Fitness functions catch cycles/ layering/coupling; they can't tell you a boundary is in the wrong place.
  • Consensus/mentorship aren't testable. The ADR + design-review templates (steps/) and the practices in CONCEPTS/GUIDE are the leverage.
  • Real enforcement is tool-specific (ArchUnit/import-linter/depguard over your actual graph).