test(e2e): add per-domain critical-path specs #335
No reviewers
Labels
No labels
area:auth
area:ci
area:db
area:infra
area:native
area:pwa
area:service
epic
feature
foundation
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
james/carol!335
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "test/e2e-per-domain-specs"
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?
What
Five per-domain Playwright specs on top of the smoke foundation (#150), exercising each major surface end to end against the assembled app (Expo RN-Web SPA → Next.js API → SQLite).
profile.spec.tstest.fixme(see below).projects.spec.tsexperience.spec.tsnetwork.spec.tsaccount.spec.tsPer-user isolation, no DB reset
Carol scopes every row to the authenticated user, so each spec just registers its own
uniqueEmail()user (newfixtures/auth.ts→registerFreshUser) and works entirely in that silo. Specs never see each other's data even on the shared per-boot DB, so no per-test reset is needed —#325does not depend on#326after all. Single-worker / serial config is unchanged.Selectors come from the i18n catalog via
fixtures/strings.ts(new namespaces follow the existingns()pattern); the avatar fixture is a real 64×64 PNG sharp can decode.testIDs added (4 total, mirroring
note-row)Only where a created entity's text is ambiguous/absent:
company-input,position-title-input— the experience job/position form inputs have no placeholder or associated label.project-name-input— the projects row-edit name input coexists with the create-card name input.Everything else asserts on the unique created name.
accessibilityRole/accessibilityLabelwere preserved.test.fixme: profile picture uploadThe profile-picture upload step is the one parked piece. expo-image-picker's web shim appends a hidden
<input type=file>and dispatches a synthetic click; headless Chromium answers with a synchronouscancelevent, so the shim removes the input within the same tick (verified: 0 file inputs remain a frame later) —setInputFilescan't race it. It's isolated as its own test so basics + contact coverage is unaffected. Re-enabling it (a picker stub, or driving the upload through the API) rides with #326's infra work.A subtlety worth flagging: expo-router keeps the previous screen mounted (hidden) on web during a push, so a name can match across stacked screens — detail-screen assertions scope with
.filter({ visible: true }).first(). Also note RN-Web 0.21 no longer reflectsaccessibilityStateasaria-checked, so the theme/locale persistence assertions check the active segment's non-transparent background instead.Verification
pnpm -F @carol/client export:web+pnpm -F @carol/api build— clean.pnpm -F @carol/e2e test— 8 passed, 1 skipped (the fixme'd picture upload); smoke spec still green.pnpm -F @carol/e2e exec tsc --noEmit— clean.pnpm -F @carol/client lint+typecheck— clean (touched experience/projects for testIDs).No CI workflow change (the existing
e2ejob runs the whole suite) and no new runtime env var.Admin coverage (invite-only + admin-approval) is deferred to #326, which needs a second app boot under a non-open
REGISTRATION_POLICY.Closes #325
Refs #150
Refs #326
🤖 Generated with Claude Code
📊 Test coverage
Patch coverage: no testable lines changed.
Overall (
app/,lib/,db/, excluding UI per ADR-0019):Soft thresholds per ADR-0019. Coverage is informational and does not block merge.
43e169d158cc04a7dde4