Remove Express Cypress references + Actions cleanup - #14003
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates CI and end-to-end tooling to stop building/starting the legacy Express app in GitHub Actions, while consolidating “specialFeatures” E2E coverage into the Next.js Cypress suite and aligning local test tooling to use port 7081.
Changes:
- Remove Express build/start (and related workflow) steps from GitHub Actions; keep Next.js build and shared unit tests.
- Move/introduce “specialFeatures” Cypress tests/utilities into
ws-nextjs-appand rely on the consolidated Next.js E2E workflow. - Update local AMP validator and Puppeteer base URL assumptions to port 7081.
Reviewed changes
Copilot reviewed 13 out of 18 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| ws-nextjs-app/cypress/support/helpers/visitPage.ts | Adds a Next.js Cypress visitPage helper including status/type checks and consent-cookie setup. |
| ws-nextjs-app/cypress/e2e/specialFeatures/utilities/cookiePrivacyBanner/index.ts | Introduces Cypress DOM helpers for privacy/cookie banner assertions using service translations. |
| ws-nextjs-app/cypress/e2e/specialFeatures/prerollAds/index.cy.ts | Ports preroll-ads Cypress spec into Next.js E2E suite. |
| ws-nextjs-app/cypress/e2e/specialFeatures/prerollAds/config.ts | Adds environment-specific URL configuration for preroll-ads checks. |
| ws-nextjs-app/cypress/e2e/specialFeatures/fontCaching/index.cy.ts | Adds font-caching Cypress coverage across multiple services/variants. |
| ws-nextjs-app/cypress/e2e/specialFeatures/fontCaching/assertions/index.ts | Adds assertions for validating cached fonts in localStorage. |
| ws-nextjs-app/cypress/e2e/specialFeatures/cookieBanner/testsForCanonicalOnly.ts | Adds canonical cookie/privacy banner behavioural tests and cookie expiry checks. |
| ws-nextjs-app/cypress/e2e/specialFeatures/cookieBanner/index.cy.ts | Wires cookie banner tests into runTestsForPage suites with smoke/non-smoke selection. |
| src/startServer.test.js | Removes Jest coverage for Express clustering/server start behaviour. |
| scripts/ampHtmlValidator/checkManifest/index.js | Switches local manifest check to localhost:7081. |
| puppeteer/runTestsForPage/index.ts | Switches Puppeteer local base URL to localhost:7081. |
| puppeteer/bundleRequests/index.test.js | Removes “modern bundle” assertions from Puppeteer bundle request tests. |
| puppeteer/bundleRequests/assertions/index.js | Updates assertions module exports after removing modern-bundle checks. |
| .github/workflows/simorgh-unit-tests.yml | Removes Express build step; continues building Next.js and running both unit test suites. |
| .github/workflows/simorgh-local-server-tests.yml | Removes Express build/start; builds/starts Next.js on 7081 for AMP/Lighthouse/Puppeteer. |
| .github/workflows/simorgh-integration-tests.yml | Removes Express integration test step; keeps Next.js integration tests. |
| .github/workflows/simorgh-e2e-special-features.yml | Deletes the dedicated “special features” Cypress workflow. |
| .github/workflows/simorgh-e2e-nextjs.yml | Simplifies Cypress install steps to only install dependencies/binary for the Next.js app. |
Comments suppressed due to low confidence (1)
puppeteer/bundleRequests/assertions/index.js:6
- This test filters JS bundle requests using
localBaseUrlfrom#testHelpers/config(currentlyhttp://localhost:7080), but Puppeteer local runs are now configured to usehttp://localhost:7081. As a result,isJsBundlewill filter out all local requests and the assertions won’t run (false positives). Update the filter to use the actual Puppeteer base URL/host for the current environment (or update the sharedlocalBaseUrlconstant in a way that doesn’t break Express tests).
import { localBaseUrl } from '#testHelpers/config';
import context from '../../context';
const isJsBundle = url => url.includes(localBaseUrl);
Contributor
Author
|
Sorry, a bunch of the changes here are moving the existing Next e2es into the 3 new folders. |
This reverts commit e3eee19.
amoore108
marked this pull request as ready for review
May 12, 2026 10:02
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.
Summary
GitHub Actions:
Buildsteps for the Express app in Github Actions as these are no longer required7081instead of7080Cypress:
specialFeaturese2e tests out of Express app and into Next.js appapplication,pageTypesandspecialFeaturescypress/e2e,cypress/supportfolders as these contents are all in the Next app. I've left the actual folders themselves to make it easier to move the Next version up to this level in the future.Testing
Useful Links