Stage 7: run the e2e suite in WebKit too (Safari-engine coverage)
Add a webkit project to the Playwright config so the hermetic mock-mode specs run in both Chromium and WebKit, and install both browsers in CI. WebKit's Debian build runs headless without extra host system libraries (verified locally: smoke + zoom pass in webkit); the workflow comment records the one-time host install-deps fallback if a runner ever lacks a library. Desktop WebKit does not reproduce iOS Safari's text auto-inflation, so the app.css text-size-adjust guard stays outside e2e coverage.
This commit is contained in:
@@ -1,8 +1,8 @@
|
|||||||
name: Tests · UI
|
name: Tests · UI
|
||||||
|
|
||||||
# Hermetic UI checks: type-check, Vitest unit tests, production build with a
|
# Hermetic UI checks: type-check, Vitest unit tests, production build with a
|
||||||
# bundle-size budget, and a Playwright smoke against the in-memory mock transport
|
# bundle-size budget, and a Playwright smoke (Chromium + WebKit) against the in-memory
|
||||||
# (no backend/gateway/Postgres). The committed src/gen/ codegen is built, not
|
# mock transport (no backend/gateway/Postgres). The committed src/gen/ codegen is built, not
|
||||||
# regenerated (the same model as the Go committed jet/fbs output).
|
# regenerated (the same model as the Go committed jet/fbs output).
|
||||||
|
|
||||||
on:
|
on:
|
||||||
@@ -51,12 +51,15 @@ jobs:
|
|||||||
|
|
||||||
# The Playwright system libraries are provisioned once on the runner host
|
# The Playwright system libraries are provisioned once on the runner host
|
||||||
# (`sudo npx playwright@<version> install-deps chromium`), so the job needs no
|
# (`sudo npx playwright@<version> install-deps chromium`), so the job needs no
|
||||||
# apt and no sudo: it only downloads the browser binary into the runner cache
|
# apt and no sudo: it only downloads the browser binaries into the runner cache
|
||||||
# (persisted by the host executor) and runs the smoke. The timeouts guard
|
# (persisted by the host executor) and runs the suite. WebKit's Debian build
|
||||||
# against a future hang. Keep this in lockstep with @playwright/test in
|
# bundles most of its own libraries and runs headless without extra host deps; if
|
||||||
# package.json — re-run install-deps on the host after a major bump.
|
# a runner ever lacks one, provision it once on the host with
|
||||||
- name: Install Playwright browser
|
# `sudo npx playwright install-deps webkit`. The timeouts guard against a future
|
||||||
run: pnpm exec playwright install chromium
|
# hang. Keep this in lockstep with @playwright/test in package.json — re-run
|
||||||
|
# install-deps on the host after a major bump.
|
||||||
|
- name: Install Playwright browsers
|
||||||
|
run: pnpm exec playwright install chromium webkit
|
||||||
timeout-minutes: 5
|
timeout-minutes: 5
|
||||||
|
|
||||||
- name: E2E smoke (mock)
|
- name: E2E smoke (mock)
|
||||||
|
|||||||
@@ -18,5 +18,12 @@ export default defineConfig({
|
|||||||
reuseExistingServer: !process.env.CI,
|
reuseExistingServer: !process.env.CI,
|
||||||
timeout: 60_000,
|
timeout: 60_000,
|
||||||
},
|
},
|
||||||
projects: [{ name: 'chromium', use: { ...devices['Desktop Chrome'] } }],
|
// Run the same hermetic specs in Chromium and WebKit (Safari's engine) so the UI is
|
||||||
|
// exercised in both rendering/JS engines. Note: desktop WebKit on Linux does not
|
||||||
|
// reproduce iOS Safari's text auto-inflation, so the `text-size-adjust` guard in
|
||||||
|
// app.css is not regression-covered here — but engine-level CSS/JS differences are.
|
||||||
|
projects: [
|
||||||
|
{ name: 'chromium', use: { ...devices['Desktop Chrome'] } },
|
||||||
|
{ name: 'webkit', use: { ...devices['Desktop Safari'] } },
|
||||||
|
],
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user