Add 1p wallet chooser layout test suite + harness (tooling only)#179
Merged
Conversation
Land the automated tooling on its own, with no style changes, so the dialog's CSS can be reworked later against code we own (after the components we use are pulled out of vue-web-request-mediator and that dependency is removed). - Add a dev-only `/test/wallet-chooser` harness route that mounts the presentational dialog with fake state across wallet counts and the cross-device QR section. Excluded from production builds. - Add a Playwright geometric-invariant suite (`npm run test:e2e`) on desktop Chromium, WebKit, and Firefox plus emulated iPhone and Pixel sizes: expected hints render, no scrollbar, header pinned while the list scrolls, panel fills the popup, header border bleeds edge to edge, expander/QR behave per wallet count. - Add a screenshot gallery (`npm run gallery`) that captures every state across themes and engines and builds a contact sheet. - Document both commands in the README. `web/app.less` is unchanged from main; no production behavior or styles change. The strict "no horizontal overflow" assertion is skipped: it fails only because the dialog still relies on the `overflow-x: hidden` band-aid to hide a real overflow, which is the deferred CSS work. The test stays in the suite as the guard that will prove the band-aid can be removed. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
`test.fixme` reports the deferred "has no horizontal overflow" check as a known-broken test to re-enable, instead of a silent skip, so the CSS rework that removes the `overflow-x: hidden` band-aid is visible in the runner output as outstanding work. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add a `test-e2e` job as a sibling of the lint job (both run in
parallel, no `needs:`). It installs the Playwright browsers, maps the
`authn.localhost` server domain to loopback so the auto-started dev
server is reachable, and runs `npm run test:e2e` across the desktop
and emulated-phone projects.
Set `permissions: {}` and rename the workflow to reflect that it now
lints and tests.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
In CI, emit the `github` reporter alongside `list` so failed and skipped/fixme tests surface as inline GitHub annotations on the run and PR, instead of collapsing into the summary's skipped count. Keep plain `list` locally, where the workflow-command output is just noise. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Hold off on running the layout suite in CI for now. Revert the `test-e2e` workflow job and the CI-only `github` reporter, leaving the lint workflow as it was. Leave the "has no horizontal overflow" test active (not skipped or fixme) rather than green-by-deferral. It fails today against the band-aid CSS, so a local `npm run test:e2e` run shows it red as a standing reminder of the deferred CSS rework; since the suite is not in CI, the failure gates nothing. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
msporny
reviewed
Jun 14, 2026
Assembling this branch pulled `package.json`/`package-lock.json` from an older harness branch cut before `main` reached 7.4.4, which dragged its stale `7.4.3` version back in — a backwards version bump. Set the version to 7.5.0 to match the CHANGELOG entry for the added tooling, and sync the lockfile. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
dlongley
approved these changes
Jun 14, 2026
dlongley
left a comment
Contributor
There was a problem hiding this comment.
Thanks, I'll apply my suggestions and merge this in.
Co-authored-by: Dave Longley <dlongley@digitalbazaar.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Lands the automated test tooling for the first party wallet chooser dialog with no style changes, so the dialog's CSS can be reworked later against code we own — after the components we use are pulled out of
vue-web-request-mediatorand that dependency is removed.This supersedes the tooling portion of #177. #177 also changed
web/app.less; this branch deliberately does not (web/app.lessis byte-identical tomain).What's here
/test/wallet-chooser?hints=N&qr=1mounts the presentational dialog with fake state across wallet counts (0/1/5/15) and the cross-device QR section. No CHAPI registration, wallets, popups, or certs. Excluded from production builds (NODE_ENV !== 'production').npm run test:e2e) — Playwright geometric invariants on desktop Chromium, WebKit, Firefox + emulated iPhone 15 and Pixel 7. Asserts structure, not pixels: expected hints render, no scrollbar, header pinned while the list scrolls, panel fills the popup, header border bleeds edge-to-edge, expander/QR behave per wallet count. A small custom reporter (test/e2e/totalsReporter.js) prints an explicitTotals: N/M passedline at the end of the run, alongside the defaultlistoutput, so the total test count is visible without scrolling up and summing the per-outcome counts (currently 215 = 43 states/assertions × 5 browser projects).npm run gallery) — every state × theme × engine, collapsed and expanded, with anindex.htmlcontact sheet. Output in the git-ignoredtest/e2e/gallery/.One intentionally-failing test
has no horizontal overflowis an active test that fails today — left red on purpose, not skipped orfixme'd. It fails because the dialog still relies on theoverflow-x: hiddenband-aid to hide a real overflow (the headers/separators bleed their border with a negative side-margin that overhangs the border-box flex layout). Runningnpm run test:e2elocally shows it red as a standing reminder of the deferred CSS work. Once the styles are reworked (see Sequencing), it turns green and proves the band-aid can be removed.Testing
npm run test:e2elocally →Totals: 190/215 passed · 25 failed. The 25 failures are thehas no horizontal overflowcases (one per wallet-count state × 5 engines), which fail as described above; everything else is green.npm run gallerygreen; lint clean;web/app.lessunchanged frommain.CI: deferred for now
This PR intentionally does not run the layout suite in CI — the lint workflow is unchanged, and there's no
test-e2ejob. If we wired it in now, that job would be red on every push/PR because of the intentionally-failing overflow test above. Our deploy (packaging.yml) triggers onv*tags and does not depend on the test workflow, so a red suite wouldn't actually block a release — but a perpetually-failing check is noise we don't want while the CSS fix is outstanding.How to add it later (once the overflow test passes), as a sibling of the lint job in
.github/workflows/main.yml:Verified working: this exact job ran green in CI on an earlier commit of this branch (lint 30s, e2e ~2m18s across all five projects) before the overflow test was made active. Optionally pair it with the
githubPlaywright reporter (reporter: process.env.CI ? [['list'], ['github']] : 'list') to surface failed/skipped tests as inline annotations on the PR.Sequencing (after this lands)
vue-web-request-mediatorpieces into authn.io and drop the dependency.has no horizontal overflowtest then passes, and CI can be wired in per the snippet above.