agent-desktop/tests/fixtures
Lahfir e3e1872ff3
feat: add trace viewer and replay artifacts
Adds the trace read/replay layer on the session-first foundation: `trace show` merges per-process segments into one deterministic timeline (bounded JSON for agents), and `trace export` renders a single self-contained, XSS-safe HTML viewer for humans. Opt-in `session start --screenshots` captures pre/post-action screenshots and refmap copies; command.start/end boundary events and a versioned trace.meta header make a step-by-step replay reconstructable. Redaction is hardened so raw caller arguments never leak into trace-reachable error messages. Available across CLI, batch, and FFI.
2026-07-02 11:48:06 -07:00
..
trace_show/trace feat: add trace viewer and replay artifacts 2026-07-02 11:48:06 -07:00
drilldown-refmap.json feat: progressive skeleton traversal with ref-rooted drill-down (#20) 2026-04-16 01:46:31 -07:00
README.md feat: Phase 1 foundation — workspace scaffold, core engine, macOS adapter, 31 commands 2026-02-19 10:44:38 -08:00
skeleton-tree.json feat: progressive skeleton traversal with ref-rooted drill-down (#20) 2026-04-16 01:46:31 -07:00

Test Fixtures

Golden JSON snapshots for regression testing.

Populating Fixtures

Run the following on macOS with Accessibility permissions to capture real snapshots:

cargo build --release
./target/release/agent-desktop snapshot --app Finder > tests/fixtures/finder-snapshot.json
./target/release/agent-desktop snapshot --app TextEdit > tests/fixtures/textedit-snapshot.json
./target/release/agent-desktop list-apps > tests/fixtures/list-apps.json

Usage in Tests

Fixture files are loaded in tests to assert serialization stability:

let expected: Value = serde_json::from_str(
    include_str!("../fixtures/finder-snapshot.json")
).unwrap();

Any change to the JSON output contract must be accompanied by updated fixtures.