diff --git a/test/e2e/README.md b/test/e2e/README.md index 4134a37..50ac57d 100644 --- a/test/e2e/README.md +++ b/test/e2e/README.md @@ -73,12 +73,14 @@ concluding anything from a 404. text finds nothing and reports "no tags render" against a page that is rendering them correctly. -**A headed browser will not launch from an agent shell here.** Both -`chromium.launch()` and `launchPersistentContext()` time out on the handshake -despite `DISPLAY=:0` being set; headless works. Interactive flows (the admin -login, `docker-credential-atcr login`) still need a human at a real browser — -but non-interactive page checks can run headless, and `batch10-anonpull.mjs` -does. +**Headed works; if it times out, retry before concluding otherwise.** A headed +`launchPersistentContext` normally comes up in well under a second — the +display is reachable (`DISPLAY=:0`, `XAUTHORITY` set to the mutter XWayland +cookie, both the Wayland socket and `/tmp/.X11-unix/X0` present; `xdpyinfo` +confirms it). Two launches did once hang for the full 180s handshake timeout +under heavy concurrent docker and test load, which is easy to misread as "headed +is impossible here" and switch everything to headless. It is not. Check +`xdpyinfo` and retry. **Logged-out checks need their own profile.** `lib.mjs`'s `PROFILE` is signed in, and clearing its cookies costs an interactive re-login for everything else. diff --git a/test/e2e/batch10-anonpull.mjs b/test/e2e/batch10-anonpull.mjs index 42570c0..f68589a 100644 --- a/test/e2e/batch10-anonpull.mjs +++ b/test/e2e/batch10-anonpull.mjs @@ -18,6 +18,8 @@ import { APPVIEW } from './lib.mjs'; const HOLD = process.env.ATCR_HOLD_URL ?? 'http://127.0.0.1:8080'; const HANDLE = process.env.ATCR_E2E_HANDLE ?? 'evan.jarrett.net'; const REPO = process.env.ATCR_E2E_REPO ?? 'valtest'; +// Defaults to headed, which is how these are meant to be watched. +// ATCR_E2E_HEADLESS=1 for unattended runs. const HEADLESS = process.env.ATCR_E2E_HEADLESS === '1'; const captain = await fetch(