chore(cypress): extract cypress into top-level package and upgrade to v15#2257
chore(cypress): extract cypress into top-level package and upgrade to v15#2257wreality wants to merge 14 commits into
Conversation
✅ Deploy Preview for pilcrow-docs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Move cypress tests from client/test/cypress to a top-level cypress/ directory with its own package.json so cypress can be installed and run independently of the Quasar client build. - New cypress/ package with its own eslint config and cypress.config.cjs - Remove cypress deps and eslint overrides from client/ - Drop test/cypress from client/tsconfig.json exclude - Update root package.json, .lando.extras.yml, e2e workflow and docs to reference the new cypress/ path
- Bump cypress to v15 in cypress/package.json and lockfile - Fix browser launch config in cypress.config.cjs for v15 - Resolve SSL and node engine errors in the cypress container - Update do-test-e2e workflow for the new cypress version
Add a lint-cypress job that runs yarn lint in the new cypress/ package on PRs touching cypress files, and wire a cypress path filter into the changes job.
7467695 to
4ac72b7
Compare
Collaborative Community Review Upstream
|
||||||||||||||||||||||||||||
| Project |
Collaborative Community Review Upstream
|
| Branch Review |
chore/cypress-reorg
|
| Run status |
|
| Run duration | 03m 05s |
| Commit |
|
| Committer | Brian Adams |
| View all properties for this run ↗︎ | |
| Test results | |
|---|---|
|
|
0
|
|
|
0
|
|
|
1
|
|
|
0
|
|
|
114
|
| View all changes introduced in this branch ↗︎ | |
…handling The build-image action's version output is empty because pilcrow-toolkit's parse-build-output never sets it. Work around this by extracting the version from the tags output instead. Also fix the resetDb cypress task which crashed the config file on GraphQL errors due to a missing return before reject().
The fpm image doesn't include the SSL cert verification fix that was added to the unit-test Dockerfile stage. Add it at runtime in the start-stack action before running migrate:fresh.
Sanctum needs the port in stateful domains for non-standard ports. Without this, session cookies aren't sent on localhost:8888 requests, causing all authenticated tests to fail.
gmeben
left a comment
There was a problem hiding this comment.
I can't get cypress to install or run. cd cypress && lando cypress run results in the error:
error Command "cypress" not found.
cypress/base:18.16.1 is Node 18, but Cypress 15 requires Node 20+. The --ignore-engines flag silenced the install-time check but left a broken install (missing node_modules/.bin/cypress), which surfaced as `error Command "cypress" not found.` from `lando cypress run`. Bump the service to node:22 / cypress/base:22.20.0 to match the CI workflow's Node 22, and drop the no-longer-needed --ignore-engines. Update the matching snippet in docs/developers/testing.md.
|
Bumped the service to Node 22 / lando extras disable cypress
lando extras enable cypress
lando rebuild -y -s cypress
lando cypress run |
# Conflicts: # client/package.json # client/yarn.lock
Carries forward the axe-core bump from master (originally in client/package.json) into cypress/, where the dep now lives after the cypress extraction.
# Conflicts: # .github/workflows/testing.yml # .lando.extras.yml # client/eslint.config.js # client/package.json # client/yarn.lock # package.json
✅ Deploy Preview for pilcrow-docs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Fallow audit reportNo GitHub PR/MR findings. Generated by fallow. |
Fallow audit report0 inline findings selected for GitHub review. |
Diff CoverageDiff: origin/master...HEAD, staged and unstaged changesNo lines with coverage information in this diff. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #2257 +/- ##
==========================================
+ Coverage 65.60% 65.67% +0.07%
==========================================
Files 327 327
Lines 7413 7430 +17
Branches 703 703
==========================================
+ Hits 4863 4880 +17
Misses 2439 2439
Partials 111 111
Flags with carried forward coverage won't be shown. Click here to find out more.
|
Diff CoverageDiff: origin/master...HEAD, staged and unstaged changes
Summary
|
The email redaction added in #2286 left review coordinators unable to reinvite staged reviewers: the reinvite mutations are authorized for coordinators (updateReviewers / updateReviewCoordinators) but take the target's email as input, which the coordinator could no longer read. Extend UserPolicy::viewEmail so a coordinator can see emails of reviewers and fellow coordinators on submissions they coordinate. Submitters on those submissions stay redacted.
Title editing became author-only and draft-only when updateSubmission was dissolved, but the only renaming UI (SubmissionTitle on the details page) is unreachable for drafts — the router redirects draft details to the draft page, which has no title editor. Skip the test until renaming has a working surface again.
Summary
Reorganizes cypress tests into their own top-level
cypress/package so they can be installed and run independently of the Quasar client build, then upgrades cypress to v15.client/test/cypress→cypress/with its ownpackage.json,yarn.lock, eslint config, andcypress.config.cjs. Removes cypress deps and eslint overrides fromclient/. Updates rootpackage.json,.lando.extras.yml, the e2e workflow, and docs to reference the new path.lint-cypressjob and acypresspath filter so cypress-only changes trigger the right jobs.Test plan
lando rebuildbrings up the cypress service cleanlycd cypress && lando cypress runpassescd cypress && yarn lintpasseslint-cypressjob runs on cypress-touching PRsdo-test-e2e) runs cypress fromcypress/