Expand description
Deterministic assertions: the primary mechanism, and no model is involved (spec §27.6).
The specification is explicit that these checks must not be delegated to a judge, and the reason is worth restating: a judge asked “did this turn send the rebooking?” answers from the text of the reply, and the text of the reply is precisely the thing that can be wrong. Whether an effect happened is a fact about the command journal and the event ledger, and reading it costs nothing.
Nine expectations are checked here, matching the list of §27.6: the normalized acts, the target resolution, the compiled commands, the emitted events, the case revision, the interaction status, the response block types, the turn’s outcome, and — the one that is a claim about absence — the forbidden effects.
A tenth is not an expectation an item writes, and exists so the other nine stay honest: an observation whose event ledger was cut short by a configured bound fails every item that claims anything about events, because a forbidden event hiding in the half nobody read would otherwise report a green safety row.
A failure carries the expectation it belongs to, what was expected, and what actually happened, so the message alone is enough to act on:
commands: expected [trip.set_travel_date], got [trip.set_name]Structs§
- Assertion
Failure - One deterministic expectation that did not hold.
Enums§
- Expectation
Name - Which of the §27.6 expectations a failure belongs to.
Functions§
- check
- Checks every expectation of an item against one observed run.