feat(test): adopt @playwright/test + ship playwright.config.js + visual scaffold (P1 #10 step 2) #18
No reviewers
Labels
No labels
agent-context-drift
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: rstillwell/deckhearth#18
Loading…
Reference in a new issue
No description provided.
Delete branch "convoy/adopt-playwright-smoke"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Closes P1 #10 step 2 / launch sequence step 10 in
.convoys/ship-readiness.md. Three previous convoys laid the infra (bump-next-jsgot Vercel deploys working again,fix-vercel-deployment-protection-in-cigot the wait-action through the SSO challenge,fix-layout-default-usershipped the sign-in UI the smoke spec asserts on); this convoy wires the actual@playwright/testdep, theplaywright.config.jsthat bridges env toextraHTTPHeaders, three npm scripts, and a single visual spec so the screenshot workflow has something to discover.After merge, every PR's
Playwright smokeworkflow reachesnpx playwright testand runs the 3 existing smoke tests against the Vercel preview — either green or red on real assertions, no more "playwright not installed" fast-fail.Convoy artifacts
.convoys/adopt-playwright-smoke.md(architect ratified 6 decisions: 3 self + 3 operator).convoys/adopt-playwright-smoke/brief-1-wire-playwright-and-visual-spec.md3ac527ec72d006Decisions ratified
.tsvs.jsfor specsnpx eslint tests/smoke/app.smoke.spec.tsexits 0 todaylib/rate-limit.jsfail-closed (AGENTS.md Gotcha #12)snapshotPathTemplatehas no{platform}token, so Mac-generated baseline would silently overwrite Linux CI baseline. Queuedseed-visual-baselines-on-linux.tests/test:runpatternDiff
5 files, +246 / -1. Mechanical lockfile churn dominates the byte count:
tests/smoke/app.smoke.spec.tsis byte-identical (Decision 1).eslint.config.mjsuntouched (Decision 5). Workflow YAML untouched (PR #17 owned it).AGENTS.mduntouched (doc-writer pass at convoy close handles the seed-on-Linux runbook).Two implementer deviations (both behavior-neutral, lint-preserving)
A — removed unused
eslint-disable-next-line no-consoledirectiveThe architect's verbatim shape would have regressed lint baseline (128 → 129) because the active
eslint.config.mjsdoesn't enableno-consolefor repo-root config files, making the directive itself reported as unused. Resolution: removed directive, added explanatory comment in its place. Theconsole.warnitself is unchanged. Documented in commit message.B — placed
@playwright/testfirst indevDependencies(alphabetical)The brief's prose said "between
@testing-library/reactandautoprefixer" but@p<@talphabetically. Resolution: placed FIRST in devDeps to preserve alphabetization per the brief's overarching principle.Verification
npm cinpm run lintnpm run test:run(vitest)npx playwright --version1.60.0npx playwright test --list --project=smoketests/smoke/app.smoke.spec.tsnpx playwright test --list --project=visualtests/visual/homepage.spec.tsnpm run test:smoke, noBASE_URL, noCI)CI=true npm run test:smoke)Expected CI behavior
With
@playwright/test+ config + bypass header now wired:Playwright smoke: wait-action ~200ms → npm ci + browser install → 3 smoke tests run against Vercel preview withx-vercel-protection-bypassheader set. Either green or red on real assertions.Screenshot diff: NOT triggered on this PR (path filter excludes test-infra-only PRs). Will fire on next PR touchingpages/**/components/**/styles/**. First run will fail (no baseline yet) butcontinue-on-error: trueswallows it and the comment-on-PR step posts the run link.First-time baseline seeding (post-merge follow-up)
The
seed-visual-baselines-on-linuxconvoy will:npm run test:visual:updateinmcr.microsoft.com/playwright:v1.60.0-nobleDocker (so the PNG matches what Linux CI produces)tests/visual/__screenshots__/home.pngtests/visual/homepage.spec.tshas an inline JSDoc comment documenting this exact procedure with the verbatim Docker command.Out of scope (deferred / pre-existing)
seed-visual-baselines-on-linux— first-run baseline curation in a Linux env (architect Boot-the-brief Finding 7)test:job in.github/workflows/ci.yml— P1 #10 step 3 in ship-readiness; separate convoyAGENTS.md§ 7 seed-on-Linux runbook — doc-writer pass at convoy closeTest plan
npm ciexits 0npm run lintmatches 128 baselinenpm run test:run21/21--list) works for both projectsPlaywright smokereachesnpx playwright teststep (verify post-push)Made with Cursor
The latest updates on your projects. Learn more about Vercel for GitHub.
Pipeline Health
Build + CI gates
Build runs on Vercel; this CI runs lint and schema-map drift only (no duplicate build).
Role reports
See individual comments above for details. This rollup updates automatically.