Accumulated uncommitted work: GHOST Web backend, WebGL/GPU web layer, web workflow engine and protocol, tooling, docs and task records. Large generated evidence, user-testing archives, build snapshots and imported test assets remain untracked. Co-Authored-By: Claude Code <noreply@anthropic.com>
24 lines
1.5 KiB
JavaScript
24 lines
1.5 KiB
JavaScript
import { createRequire } from "node:module";
|
|
import path from "node:path";
|
|
const { chromium } = createRequire(import.meta.url)(path.resolve("web/node_modules/playwright"));
|
|
const browser = await chromium.launch({ headless: true, executablePath: "/usr/bin/google-chrome-stable",
|
|
args: ["--no-sandbox","--use-gl=swiftshader","--enable-unsafe-swiftshader","--enable-unsafe-webgpu","--enable-dawn-features=allow_unsafe_apis","--use-webgpu-adapter=swiftshader"] });
|
|
const ctx = await browser.newContext({ viewport: { width: 1440, height: 900 } });
|
|
const page = await ctx.newPage();
|
|
await page.goto("http://127.0.0.1:5412/", { waitUntil: "domcontentloaded" });
|
|
await page.waitForFunction(() => document.body.innerText.includes("WASM ABI: ready"), undefined, { timeout: 120000 });
|
|
await page.getByTestId("blend-file-input").setInputFiles(path.resolve("tests/files/web/hierarchy_simplify_combined.blend"));
|
|
await page.waitForFunction(() => /SceneIR r\d+/.test(document.querySelector('[data-testid="engine-status"]')?.textContent ?? ""), undefined, { timeout: 120000 });
|
|
await page.waitForTimeout(5000);
|
|
// The native workspace's area layout lives in the snapshot's editor workflow.
|
|
const layout = await page.evaluate(() => {
|
|
const text = document.querySelector('[data-testid="editor-workflow-context"]')?.textContent;
|
|
return text ?? null;
|
|
});
|
|
console.log("CTX", layout);
|
|
console.log("AREAS", JSON.stringify(await page.evaluate(() => {
|
|
const nodes = [...document.querySelectorAll('[data-workspace-id]')];
|
|
return nodes.map(n => n.textContent).slice(0, 16);
|
|
})));
|
|
await browser.close();
|