Skip to content

[dspace-8_x] Upgrade to Cypress 15.21.2, test on Node 20 and 22, remove Node 18 testing - #6560

Open
bram-atmire wants to merge 2 commits into
DSpace:dspace-8_xfrom
bram-atmire:6559-cypress-15-node-20-22-8_x
Open

bram-atmire wants to merge 2 commits into
DSpace:dspace-8_xfrom
bram-atmire:6559-cypress-15-node-20-22-8_x

Conversation

@bram-atmire

@bram-atmire bram-atmire commented Nov 24, 2026 •

Copy link
Copy Markdown
Member

References

Description

Upgrades dspace-8_x to Cypress 15.21.2, which fixes the e2e crash on Chrome 158, and moves the CI test matrix from Node 18/20 to Node 20/22 because Cypress 15 requires Node 20 or later.

Instructions for Reviewers

As described in #6559, e2e tests on dspace-8_x fail on Chrome 158 with Error: * is not a valid URL. The fix is only in Cypress 15.21.2, which requires Node ^20.1.0 || ^22.0.0 || >=24.0.0. When main moved to Cypress 15 in #5444, 8.x stayed on Cypress 14 because of Node 18. Node 18 reached end of life in April 2025, and the 8.x Docker images already use node:22-alpine.

List of changes in this PR:

  • package.json / yarn.lock: cypress from ^14.5.4 to ^15.21.2. The other lockfile changes are Cypress 15's own dependencies. systeminformation is locked at 5.33.19, the same version as on main.
  • .github/workflows/build.yml: test matrix from [18.x, 20.x] to [20.x, 22.x], same as dspace-9_x. The code coverage upload moves from the 18.x job to the 20.x job, otherwise no coverage report would be uploaded.
  • cypress/e2e/homepage.cy.ts: wait for loading components before the accessibility check (cherry-pick of 149feee from Show restricted thumbnails to users with access rights #4249), which fixes a timing-dependent link-name failure.

Branch protection must change before merging: the required checks for dspace-8_x include tests (18.x), which this PR no longer produces. A repository admin needs to replace tests (18.x) with tests (22.x) in the branch protection rule just before merging.

How to test

  • The e2e tests in tests (20.x) and tests (22.x) should run all 57 specs instead of stopping at the second one.
  • Locally: yarn install --frozen-lockfile and npx cypress verify, then yarn e2e against a backend with the e2e test data.

Checklist

  • My PR is small in size (e.g. less than 1,000 lines of code, not including comments & specs/tests), or I have provided reasons as to why that's not possible.
  • My PR passes ESLint validation using yarn lint
  • My PR doesn't introduce circular dependencies (verified via yarn check-circ-deps)
  • My PR includes TypeDoc comments for all new (or modified) public methods and classes. It also includes TypeDoc for large or complex private methods.
  • My PR passes all specs/tests and includes new/updated specs or tests based on the Code Testing Guide.
  • If my PR includes new libraries/dependencies (in package.json), I've made sure their licenses align with the DSpace BSD License based on the Licensing of Contributions documentation.
  • If my PR includes new features or configurations, I've provided basic technical documentation in the PR itself.
  • If my PR fixes an issue ticket, I've linked them together.

AI Disclosure

Claude Code (claude-opus-5-5) prepared the package, lockfile and workflow changes and checked the new lockfile entries (release age, provenance, install scripts). Verified locally with yarn install --frozen-lockfile and npx cypress verify; e2e tests run in CI

My human review didn't spot any particular logical mistakes or problems.

…ve Node 18 testing

Cypress 14 cannot run e2e tests on Chrome 158 (cypress-io/cypress#35195),
and the fix is only in Cypress 15.21.2, which requires Node 20 or later.
Test on Node 20.x and 22.x like dspace-9_x, and upload code coverage
from the 20.x job.

systeminformation is locked at 5.33.19, the same version as on main.

Fixes DSpace#6559

Assisted-by: Claude Code [claude-opus-5-5]
@alanorth alanorth added the 1 APPROVAL pull request only requires a single approval to merge label Nov 25, 2026
@alanorth alanorth added this to the 8.6 milestone Nov 25, 2026
@alanorth

Copy link
Copy Markdown
Contributor

Thanks @bram-atmire. I am in favor of this, but we need @tdonohue or @lgeggleston to help with the repository admin parts.

As a followup, I wonder if we should also remove Node.js 20 from the testing matrix because it reached end of life on 2026-03-24 and there are increasing warnings about it in CI as well. The README and Wiki should be updated to say DSpace 8.x supports Node.js 18, 20, and 22 though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

1 APPROVAL pull request only requires a single approval to merge

Projects

Development

Successfully merging this pull request may close these issues.

3 participants