The chromium-webgpu Playwright project: what it changes, in one place.
The default chromium project drives the viewer through THREE.WebGLRenderer,
and the handful of specs that ask for ?renderer=webgpu there land on
WebGPURenderer's internal WebGL2 backend, because Playwright's bundled
headless Chromium has no hardware WebGPU adapter. So WGSL codegen, real
adapter limits and the 256-byte readback row padding were exercised by no
automated run at all.
The chromium-webgpu project (opt-in, pnpm test:e2e:webgpu; see
playwright.config.ts) runs the same specs on system Chrome with a real
adapter. Three things make that a NATIVE run rather than a relabelled one:
withWebGPURenderer: the shared fixture appends renderer=webgpu
to every viewer URL the spec did not already pin with renderer=.
waitForLuxarReady (helpers.ts) fails fast, through
requiresNativeWebGPU, when such a page did not come up on a
native, non-fallback WebGPU backend. It also rejects viewer pages that
bypassed the URL rewrite. A silent WebGL2 fallback would turn
the whole project into a second copy of the default one.
skipUnlessWebGL keeps out the specs that drive raw WebGL
(WEBGL_lose_context, a webgl2 context's own error queue), which have
nothing to observe on a canvas already in webgpu mode.
This module deliberately imports nothing from helpers.ts, which imports it.
The
chromium-webgpuPlaywright project: what it changes, in one place.The default
chromiumproject drives the viewer throughTHREE.WebGLRenderer, and the handful of specs that ask for?renderer=webgputhere land onWebGPURenderer's internal WebGL2 backend, because Playwright's bundled headless Chromium has no hardware WebGPU adapter. So WGSL codegen, real adapter limits and the 256-byte readback row padding were exercised by no automated run at all.The
chromium-webgpuproject (opt-in,pnpm test:e2e:webgpu; seeplaywright.config.ts) runs the same specs on system Chrome with a real adapter. Three things make that a NATIVE run rather than a relabelled one:renderer=webgputo every viewer URL the spec did not already pin withrenderer=.waitForLuxarReady(helpers.ts) fails fast, through requiresNativeWebGPU, when such a page did not come up on a native, non-fallback WebGPU backend. It also rejects viewer pages that bypassed the URL rewrite. A silent WebGL2 fallback would turn the whole project into a second copy of the default one.WEBGL_lose_context, awebgl2context's own error queue), which have nothing to observe on a canvas already inwebgpumode.This module deliberately imports nothing from
helpers.ts, which imports it.