2 Commits
Author SHA1 Message Date
WaleedandClaude Opus 5.5 ca57a3b3ff improvement(desktop-e2e): one shared harness with a bounded quit, flake fixes, and a trimmed suite (#10390)
* improvement(desktop-e2e): shared launch fixture with a bounded, diagnosed quit

* improvement(desktop-e2e): shared fixture bundling and tool authorization

* improvement(desktop-e2e): split local-files onto the shared harness and fix live-sim consent handling

local-files: four tests (consent, Full file access, fs races, restart/sign-out) on the desktop
fixture with bounded restarts; a minimal fixture page replaces apps/sim's Settings component;
the shared-prompt step waits for a real join; fs patches restore in finally and assert they ran.

desktop-tools-live-sim: launches through the harness, approves only folder consent dialogs,
and merges the two awaiting-approval tests into one launch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* improvement(desktop-e2e): move source-connect, page dialogs, and sign-in prompts onto the shared harness

- Launch, servers, fixture bundling, tool authorization, focus, and panel bounds come from the
  harness; Chromium for source-connect is Playwright's own context fixture. Report files and
  check() wrappers give way to test.step.
- browser-page.ts shares the shell fixture server, browser-chrome actions, and exact-URL page
  reads and trusted input between the dialogs and sign-in specs.
- Typed input is awaited until it lands before the next action; page lookups match the exact URL.
- Sign-in links record clicks so "nothing happened" checks only run after a click landed; the
  sign-in retry loop and the two-outcome passkey Enter check are gone; the suite is split into
  two tests so it no longer needs a longer timeout.
- source-connect waits for observable effects before asserting a stale callback, a repeated
  Connect, and the retried inventory left state alone; page errors are asserted at the end.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* improvement(desktop-e2e): background executor and terminal cancel on the shared harness

Launch through the desktop fixture (launchAgainst), so every app quits under a
deadline and every profile, ZDOTDIR and temp dir is removed. Replace fixed
sleeps with condition waits (journal state, inbox reads, a tmux attachment
probe, a control run for relaunch recovery), deliver user input before the
agent acts, make tmux required in CI, and drop or merge tests other suites
already cover.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* improvement(desktop-e2e): move shell, quick chat, autofill, session, updater and packaged specs onto the shared harness

Every spec launches through the desktop fixture with a bounded quit, binds
fixtures to loopback, and records checks as test.step. Merges duplicate
launches in smoke and continue-sign-in, folds the packaged launch-telemetry
check into the offline-page launch, replaces fixed sleeps and one-shot reads
with condition waits, and deletes the check-report file report.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* improvement(desktop-e2e): drop dead env and report plumbing; share launch, quit and fixture styles

* improvement(desktop-e2e): move browser tools, chrome, focus, and page-parity specs onto the shared harness

Browser tools share one app across read-only tests with a disposed provisional scope per test;
window-state and sign-out tests launch their own. Fixes focus, fire-and-forget IPC, and
load races; drops unasserted screenshots, the duplicate confirm-dialog check, and the
fixture-decided terminal test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* improvement(desktop-e2e): browser tools and chrome use the shared launch, quit and bundling

* chore(knip): drop the deleted worker-restart fixture entry

* fix(desktop-e2e): renew panel bounds, keep the child process, one app per browser-tools test, quit before cleanup

* fix(desktop-e2e): correct three migrated waits and keep the real toast timer

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-24 16:22:58 -08:00
Waleed b26b436c54 ci: balance macOS Electron smoke shards by measured duration (#9315)
* ci: balance desktop smoke shards by observed file durations

* test: verify balancing guards and document duration evidence

* style: use the script alias for shard planning

* fix: select Playwright file suites rather than test declaration locations

* test: prove desktop discovery preserves imported and unmeasured cases
2026-10-22 13:44:54 -07:00