Prefer installed CLI or real MCP stdio workflows with native evidence, then integration tests across the affected boundary, then golden examples for format projections and serialization. Extend an existing workflow when it can prove the regression. Keep narrower tests for distinct contracts those workflows cannot reliably reach; use fault injection for otherwise inaccessible failure boundaries. Assert observable outcomes rather than private cache state or internal calls. When testing a termination cause, keep unrelated limits permissive so they cannot win the race.
For transport changes, check advertised schemas against accepted inputs and emitted results, including relevant failures, continuation, and recovery. Derive the expected tool catalog from the operation registry. Documentation-only edits need links and affected claims checked against their implementation; they do not require collector or performance runs.
Install development tools with uv sync --extra dev, adding provider extras as needed.
The default selection includes process tests and excludes optional and performance:
uv run pytest -qUseful selections:
uv run pytest tests/test_runtime.py -q
uv run pytest -m e2e -q
uv run pytest -o addopts='' -m golden -q
uv run pytest -o addopts='' -m requires_memray -q
uv run pytest -o addopts='' -m requires_torch -q
uv run pytest -o addopts='' -m performance --durations=0Provider selections require the matching extras and host tools. -o addopts='' removes the default
marker exclusions. Mark tests that spawn or communicate with subprocesses process; use e2e
for installed CLI or MCP workflows with real processes and native evidence, and golden for fixed
artifacts with explicit expected projections. Marker definitions live in
pyproject.toml.
CI splits the default suite into deterministic and process-boundary jobs and reports combined branch coverage without a percentage gate. Optional Memray, PyTorch, and performance jobs run on schedules and manual dispatch. Style, type, dependency, architecture, and npm checks are defined there; contributor commands are in CONTRIBUTING.md.
Hypothesis reports minimized counterexamples. Replay a generated run with
uv run pytest --hypothesis-seed=<seed> and the same test selection. With Z3 on PATH,
uv run pytest -o addopts='' -q tests/proofs checks stream accounting, paired differences
and request-limit recovery. The scaling accounting proof checks that splitting measurements at the same coordinate preserves the omission count, assuming the reader supplies accurate native and positive counts. Generated native suites exercise that assumption. The Compute Sanitizer proof checks the prefix length and per-class
counts after every record, assuming each parsed record has exactly one class. Generated XML
tests connect that model to the worker and runtime. The architecture CI job also runs those proofs.
The native input proof checks the unread budget from admission through EOF and verified state.
It assumes each descriptor read returns at most the requested byte count. Generated native
reader tests confirm that replacing a payload and restoring it before the final runtime check
cannot produce a successful result for the replacement.
The Perfetto duration model proves integer carry bounds and ordering for the three-part sums.
The Perfetto allocation proof checks the empty aggregate and each additional slice argument. Given SQL integer extrema that ignore nulls, the projection reports a byte count exactly when all observed counts agree. The trace tests exercise that assumption with the native reader. The process group model checks the broker's cleanup after a worker exits. Generated POSIX tests kill a Perfetto worker between process samples and also exercise a request timeout. The model assumes the kernel delivers the group signal and the decoder inherits its worker's group.
The Memray proof checks first-visit attribution for an arbitrary source location, record weight and bounded stack prefix. Native recursive profiles check both byte and allocation-count weights against Memray’s high-watermark and retained records.
For a fixed inventory and predicate, the pagination proof checks the initial state and each scan transition. The emitted count stays within capacity and equals the number of matches consumed. A continuation starts at the first unread match and advances beyond the previous page start. Generated repository tests exercise publication, restart, and cursor invalidation against real manifests. The arithmetic model assumes the inventory and predicate stay fixed during a scan.
The group settlement model checks that a graceful root exit or a pending signal alone cannot yield complete cleanup. The broker test reparents a group member between polls and generates root exit statuses. It also exercises hidden or unreadable members, and recovery when a later probe confirms settlement. The model distinguishes an existing group with incomplete enumeration from an authoritative absence or fully observed stopped membership.
The process population model checks the union of current descendants, process-group membership, and retained identities. It finds counterexamples for tree-only sampling and summing overlapping populations. Generated workloads allocate memory after reparenting to exercise the process budget.
The writable-tree model checks identity selection after a pathname change. POSIX tests replace queued or opened directories, resume queued work after a rename, and check the number of opens in deep trees under a descriptor limit. They distinguish a symlink target's unreadable metadata from a failure inside an admitted directory and verify descriptor closure at the file ceiling and after a metadata error. The model assumes the operating system binds directory-relative reads to the opened handle. Windows concurrent traversal awaits a matching host check.
The writable admission model finds the counterexample for launching before testing an enforced baseline. Generated broker cases cover unavailable and over-limit baselines, along with report-only execution and failure receipts without a child. A blocked baseline also exercises the launch deadline, scope cancellation, and repeated task cancellation. Each case checks that the scan settles without acquiring a sink or starting a child, including when the completed read reports an unreadable root. The baseline ownership model shows why a receipt that can release the request's paths must wait for the interrupted read to join.
The scratch commitment model checks that debiting each observed file gives the same remaining reservation as debiting the full sample. The argument applies independently to bytes and files. Generated directory layouts cover overlapping request activity, an already settled subtree, and writable roots nested inside a capture reservation.
Broker process tests hold a live or final storage sample open while an unrelated loop task runs. The POSIX cancellation case holds the sample until the child receives its termination signal and checks that the caller's receipt waits for both to settle. The writable settlement model assumes quiescent output during its final sample. It finds the missed limit when settlement is checked after a live sample or assumed from the root's exit. Generated broker cases write files beyond either ceiling before the in-flight sample returns and while a descendant still lives during cleanup.
Worker output verification checks the declared-length budget at initialization, after every read, and at the one-byte EOF probe. The model assumes each descriptor read returns at most the requested count. Filesystem tests exercise size changes between the descriptor check and the first read, and verify that later writes leave the consumer's byte snapshot unchanged. The snapshot accounting checks that all retained bytes fit the admitted bundle total.
The native decoder model finds two
counterexamples to byte-only identity and checks that an admitted invocation fixes both the
executed program and its forwarded PATH. The cache argument assumes collision-free
digests and unchanged dependencies of the invoked program. Generated tests exercise
installation changes, symlink retargeting, and a PATH change after admission.
The converter continuation model checks
that a cursor cannot admit a page with a different projection, including on a warm
analysis-cache hit. Generated tests cover relocated native inputs and changed decoder dependencies.
The converter inventory model checks that file admission uses the same member count as the verified copy. The model assumes that a successful copy materializes exactly the admitted inventory and checks the regular file and empty-directory cases. The Nsight property pages multi-table directories and verifies reused output from a generated exporter without running it again.
Perf leaf-attribution properties exercise the Linux decoder’s documented output fields with a simulated executable. Native recording and symbol resolution require a Linux perf host.
The maintained workflows cover these boundaries:
| Surface | Evidence exercised | Limit of that proof |
|---|---|---|
| CLI and MCP | Schemas, inline results, validation, continuation, preservation, rescue, restart, replay | Does not measure agents' tool-selection quality |
| Setup and update | Client formats and profile overrides, terminal consent, pinned launchers, environment forwarding, bounded failures, competing writers and POSIX directory replacement during publication | Installer shims do not prove live dependency resolution or native clients loading registrations |
| Native analysis and capture | Forked Node CPU/heap capture, failed exits and saved-input replay, Python profiles, inference and benchmark exports, pytest, coverage, streaming traces | Supplied artifacts do not establish every producer release or complete vendor capture lifecycle |
| Processes and storage | Cancellation, descendant cleanup, output and scratch bounds, FIFO substitution, corruption, source-kind changes, immutable publication | Sampled resource observations are not strict OS quotas |
| Comparisons | Native identities, exclusions, oracle outcomes, incompatible and partial coverage | Profiles alone do not establish causality or improvement |
| Scale | Publication and paginated queries across 1,000 real manifests after restart | Timings depend on corpus, workload, environment, semantic oracle, and metric |
Node replay uses a workload marker to prove it does not execute the target again. Fork coverage checks separate parent/child artifacts and hotspots after successful and nonzero exits, plus preservation of a completed child profile when the parent times out. This does not establish profile flushing on forced termination or profiling arbitrary descendants. PyTorch trace replay needs PyTorch and a local Perfetto reader. Simulated vendor-exporter failures establish cleanup and retry behavior, not installed xctrace or Nsight compatibility. Setup/update workflows do not establish project or administrator policy precedence, Windows behavior, or private-index resolution. The managed-provider stdio test follows both required and conditional reconnect actions through a launcher shim into a fresh server, checks activation against prepared distribution metadata, and compares the effective limits and returned page before and after reconnection. Real uvx preparation and native-client loading require separate matching host checks.
On POSIX asyncio, broker tests cancel the request before launch and during pipe connection after a real workload has spawned a child. They check the reported termination and verify that both processes have stopped. Windows subprocess transport acquisition requires a matching host check.
The V8 worker tests exercise exact and one-over node and sample limits in CPU and heap profiles whose nodes aggregate to a single frame. They use lowered worker budgets.
Other proof gaps include resource-baseline races and unavailable metrics. Vendor hardware, permissions, and other platforms require matching host workflows. A skipped provider test is not provider verification.
The INT96 integer model proves that a signed low-64-bit nanosecond reading and the native timestamp have the same whole second exactly when the native timestamp fits in 64 signed bits. Parquet reader properties exercise these two decodes on native files. A writer that already encoded the wrong instant consistently at both resolutions cannot be diagnosed by this check. The original artifact remains available for inspection.