CI: the page under a headless browser on every push (tests/ui, the ui job)
A job of its own on ubuntu-24.04: Node 20, playwright-core 1.65.0 installed into the runner's temp directory for the run (the repository keeps no package.json), its own Chromium with the system libraries it needs, then node tests/ui/run.mjs. Nothing is built and no server started. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2 files changed
+28
-5
No files matched your search
@@ -1,7 +1,8 @@
|
||||
# Checks on every push to main and dev and every pull request: formatting, lints, tests, the
|
||||
# page's scripts, the pins (tokens, CodeMirror), the public-repository hygiene -- and the app
|
||||
# started for real, on X11 and on Wayland, to prove it gets as far as its window. The packages
|
||||
# are built only by release.yml, from a tag.
|
||||
# page's scripts, the pins (tokens, CodeMirror, xterm), the public-repository hygiene, the page
|
||||
# itself under a headless browser (tests/ui) -- and the app started for real, on X11 and on
|
||||
# Wayland, to prove it gets as far as its window. The packages are built only by release.yml,
|
||||
# from a tag.
|
||||
name: ci
|
||||
on:
|
||||
push:
|
||||
@@ -40,11 +41,32 @@ jobs:
|
||||
run: cargo test --locked
|
||||
- name: The page's scripts parse, and none sets HTML
|
||||
run: scripts/check-ui.sh
|
||||
- name: The design tokens and CodeMirror are the server's, as pinned
|
||||
- name: The design tokens, CodeMirror and xterm are the server's, as pinned
|
||||
run: |
|
||||
scripts/fetch-tokens.sh
|
||||
scripts/fetch-vendor.sh
|
||||
|
||||
# The page (ui/) under a headless Chromium, against a stand-in for the app's bridge
|
||||
# (tests/ui/mock-tauri.js) with the server's answers as a table: nothing is built and no server
|
||||
# is started. Playwright is the library only, installed for the run and not a dependency of
|
||||
# the repository (it has no package.json), with the Chromium it was made for.
|
||||
ui:
|
||||
runs-on: ubuntu-24.04
|
||||
timeout-minutes: 20
|
||||
steps:
|
||||
- uses: actions/checkout@v5
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: 20
|
||||
- name: Playwright and its Chromium
|
||||
run: |
|
||||
npm install --no-save --no-package-lock --prefix "$RUNNER_TEMP/pw" playwright-core@1.65.0
|
||||
node "$RUNNER_TEMP/pw/node_modules/playwright-core/cli.js" install --with-deps chromium
|
||||
- name: The page under a headless browser
|
||||
env:
|
||||
NODE_PATH: ${{ runner.temp }}/pw/node_modules
|
||||
run: node tests/ui/run.mjs
|
||||
|
||||
# The app started for real: it must still be running after 25 seconds (timeout's 124), and its
|
||||
# log must not say it stopped. Once under Xvfb (X11) and once under a headless Weston (Wayland,
|
||||
# GTK's Wayland backend forced), each with a session bus (the tray and the notifications want
|
||||
|
||||
Reference in new issue
Block a user