Remove alternate hosts from tooling probes

Keep the probe suite on the Material composition so browser fixtures and capture drivers no longer render or select Cupertino hosts. Record the final residual legacy arguments and implementation checks for the delivery gate.
This commit is contained in:
2026-11-11 21:38:30 +00:00
parent 7cb95471cb
commit b60ad6d98f
68 changed files with 405 additions and 747 deletions
+4 -4
View File
@@ -12,14 +12,14 @@ import { mkdir, mkdtemp, rm } from 'node:fs/promises';
// Usage (from app/):
// flutter build web -t tool/chat_sessions_probe_entry.dart \
// --dart-define=CHAT_PROBE_STYLE=material -o build/chat-list-material
// PROBE_WEB_ROOT=$PWD/build/chat-list-material PROBE_VARIANT=material \
// PROBE_WEB_ROOT=$PWD/build/chat-list-material \
// OPENCODE_ARTIFACT_DIR=<dir> node tool/chat_sessions_probe.mjs
//
// The fixture answers the app's real protocol in-process: accepted create,
// rename, star and close calls change the list the next chat_sessions read
// returns, and the title `Refused title` is refused with the server's words.
const root = resolve(process.env.PROBE_WEB_ROOT ?? join(process.cwd(), 'build/web'));
const variant = process.env.PROBE_VARIANT ?? 'material';
const variant = 'material';
const artifactDir = process.env.OPENCODE_ARTIFACT_DIR ?? join(tmpdir(), 'chat-sessions-capture');
await mkdir(artifactDir, { recursive: true });
const mime = { '.html': 'text/html', '.js': 'text/javascript', '.json': 'application/json', '.wasm': 'application/wasm', '.png': 'image/png', '.ico': 'image/x-icon' };
@@ -181,7 +181,7 @@ try {
await delay(600);
if (!(await visibleText()).includes('Open fixture')) {
// Flutter web's semantics DOM swallows the coordinate hit for this
// Cupertino button; activate the same rendered node through its semantics
// Material button; activate the same rendered node through its semantics
// action instead of pretending the Undo happened.
const activated = await evaluate(`(() => { const e = [...document.querySelectorAll('flt-semantics')].find(x => (x.getAttribute('aria-label') || x.innerText || '') === 'Undo'); e?.click(); return !!e; })()`);
if (!activated) throw new Error('Could not activate Undo');
@@ -307,7 +307,7 @@ try {
await click('Cancel', 'Cancel after the refusal');
// A refused row action keeps the server's whole reason under its own row on
// both hosts — never one ellipsised line inside a Cupertino subtitle.
// both hosts — never one ellipsised line inside a Material subtitle.
await clickFirst('Chat actions for Closed fixture');
await click('Reopen', 'Reopen on the closed fixture');
await waitText('the chat is locked by another operator', 'the row refusal');