Skip to main content
awp-conformance runs the assertions of the requirement matrix (AWP-CNF-004). It targets 0.1-draft.12 and shares no code with any implementation: it speaks the protocol from the canonical schemas, the lifecycle table, and the matrix of the revision it pins.

Testing a world

The suite connects as one or more agents. It checks everything the world sends — schemas in receiver and sender form, status_seq sequencing and replay, every action transition against the lifecycle table, frame sequencing per channel, closing, integer bounds — and runs active tests named after the requirements they cover: version negotiation, grants and subscriptions, idempotency and conflicts, preemption, deadlines, closing during motion, lockstep advancement and its clock, streaming delivery and telemetry, the watchdog, stale intents, resumption from a partial acknowledgement, half-open connections, reconnect-window expiry, heartbeat loss, resets, session isolation, the e-stop, and the audit log. awp-conformance tests lists them; awp-conformance requirements shows which cover each ID. The suite tests every time model the manifest offers unless --mode names one, and presents --token (default $AWP_TOKEN) as the agent credential. A manifest declares action types but not which parameters make an action run long enough to interrupt, so the world supplies a fixture: two or more extended moves in one concurrency group (three, off one line, let it always pick a target the embodiment is not near), and optionally params that fail validation or leave an envelope, params that make a move outlast its type’s max_duration_ms (long_params), operator commands that engage and release the e-stop, and the directory of the audit log. The fixture for the reference world is fixtures/awp-sim.json, and fixtures/awp-sim-features.json adds the approver token and servo entry for its --features configurations. Timing-bound tests — the watchdog, heartbeat loss, reconnect-window expiry — wait as long as the world declares. max_wait_s in the fixture bounds a single wait (default 45 s); --slow lifts it.

Testing an agent

--mode picks the time model the harness offers. The suite serves the manifest from a harness world that behaves as a minimal conformant world for it, launches the agent once per episode ({url} and {token} in the command, or $AWP_URL and $AWP_TOKEN in its environment), and checks what the agent sends. The episodes supply the stimuli agent requirements need: unknown fields on every message, reserved frame flag bits, frames interleaved across channels, a redelivered terminal status, an unknown world request, a world request and frames sent between a request and its response, a pong before session.ready on another clock, a dropped connection, a world that no longer holds the session when the agent resumes, an integer beyond 2^53 − 1, a malformed frame on a stream connection, a world that falls silent, an invalid manifest, a session without action grants, and a refused submission. In streaming, one episode skips frames by seq on one channel and follows a gap with a resync frame on another, and the agent’s obs.report shows whether it counted the first as loss and not the second. In lockstep, frames on a stream connection follow the world.tick result, and the next advance shows whether the agent waited for them. What the agent does inside is seen only through what it sends. Where the matrix gives the agent side of a requirement as <id>, else manual:, the suite tests it when the agent’s messages show it — loss accounting from obs.report — and otherwise reports manual, for evidence such as the implementation’s own receiver tests.

The report

Every requirement receives one outcome: The report states the claim its outcomes support (AWP-CNF-005): AWP-conformant with no failure and nothing untested in scope, self-assessed when nothing failed but something went untested, and not conformant otherwise. --out writes report.json and a wire trace per connection in the trace format.

Beyond Core

Tests for the ws stream binding, task, approval (with approver_token in the fixture), blend, transfer, seeding, snapshots and replay, multi-bind, shared control, the barrier tick authority, and command channels (with a servo entry: its action, a setpoint, and optionally one outside the envelope) run when the world’s manifest or session.ready offers them, and report n/a otherwise. Standing approvals are tested when the safety policy declares standing_approvals; otherwise the suite checks that a response carrying one is refused. --profile sim brings the sim profile’s requirements into scope and names it in the claim, as in Core World + sim (lockstep). Not covered: grant expiry and stream bindings other than ws.