Are you an LLM? Read llms.txt for a summary of the docs, or llms-full.txt for the full context.
Skip to content

ENC Emulator

The ENC Emulator is a browser testbed that loads every app definition from the UI Kit and runs it against a real ENC node, so the full protocol stack can be previewed and exercised from a single page. It is also a required witness in the spec's release gate.

How it works

  1. Load apps. Every app's manifests are loaded; the six core enclaves are pre-mounted and the rest of the catalog is install-on-demand, keeping per-workflow boot fast.
  2. Drive the tier matrix. Each app's workflows run across 8 tiers(mem | cf) × (node | dom | hl | pw): pure SDK, happy-dom, and Playwright (headless / headed) renderings, each over either an in-process MemoryAdapter or a real Worker backend.
  3. Codegen-derived MemoryAdapter. The in-process node emulation is itself generated from the Lean spec, so the emulated node shares the protocol semantics of the real one — same RBAC, signatures, and event log, with no network.
  4. Witness. The full matrix run is the canonical coverage proof and emits a witness result the spec's release gate consumes.

What makes it sound

The same workflow corpus runs through every tier, and the matrix is a single pass that exits green only if every tier passes — the operational form of "100% coverage" (the reference run is 8 tiers × 10 apps × 123 workflows = 984 / 984). Because the emulated node is codegen-derived from the spec — not a separate mock — passing on the mem tiers means passing against the real protocol semantics. The emulator is pinned as a required witness: the spec cannot release while its matrix is red.

See also