Skip to main content

Module mock

Module mock 

Source
Expand description

The mock worker (CONTEXT.md §14, §21).

Replays a canned script — a sequence of streamed events plus a final result — without spawning any process or making any network call. This is what lets the loop engine be integration-tested (loop-backs, stuck-detection, resume) deterministically, without burning tokens or depending on a flaky beta CLI.

Structs§

MockScript
A canned scenario the mock replays. Deserializable so tests can load transcripts from JSON fixtures on disk.
MockWorker
A worker that replays a MockScript.