For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt, and this page is available as Markdown at /learn/testing-and-exercises.md.

Testing the architectural claims

Choose a test by the claim it must establish. Domain tests, adaptor tests and real-service qualification provide different evidence.

ClaimUseful evidence
An invariant rejects invalid stateDomain transition tests
An application uses the intended owner portHandler tests with explicit collaborators
State, receipts and intents commit togetherRestricted PostgreSQL atomicity and failure tests
Duplicate deliveries recover safelyBroker redelivery and receipt tests
A schema change preserves stored bytesHistorical wire fixtures and compatibility checks
A browser recovers from stale deliveryAuthenticated browser and realtime tests
A provider workflow is usable in an environmentReal-provider qualification and UAT

Follow Party and Project

Start with Party's authentication tests and Project's domain implementation. Read their context guides for the required native and broker lanes. Use TESTING.md for current commands and dev-box requirements.

Exercises

  1. Identify the aggregate that owns each Party access-state transition. Explain why an unchanged transition preserves the authentication generation.
  2. Explain how RestoreProject treats invalid saved state and why it raises no creation fact. Find the test that establishes this behaviour.
  3. Trace a complete Project observation from source validation through application admission, aggregate change and persistence. Identify the provider I/O boundary.
  4. Lose a command reply after commit. State which identity, input and expected version the retry must retain.
  5. Compare a Project material revision with its authority revision. Explain how a successful unchanged source read can affect one while preserving the other.
  6. Trace an owner contract to the API and browser. Identify where server-authorised subscriptions and missing-resource behaviour are checked.

Record remaining qualification alongside the implementation. A passing fake-backed handler test establishes no claim about PostgreSQL isolation or provider readiness.

Adapted from the architecture reference, with Pharos examples.

Page source

Source snapshot ยท Revision f928834c8.