-
Story
-
Resolution: Done
-
Critical
-
None
-
None
We are currently running Cypress v8.5.0, which is over two years old, so we should upgrade to a newer version to stay current. Recommended upgrade is v12.17.4.
Robb created a WIP PR to vet this upgrade and diagnose and fix any issues in console and OLM tests.
A few outstanding issues with that PR:
- Existing cypress.json configs and test names need to be updated. Running `cypress open` with a >= 10.x version of Cypress installed provides a wizard that covers this process. Robb has already done so for `packages/integration-tests-cypress` and `packages/operator-lifecycle-manager/integration-tests-cypress` in https://github.com/openshift/console/pull/13070. The following configs (and tests) need updating:
- packages/topology/integration-tests/cypress.json
- packages/dev-console/integration-tests/cypress.json
- packages/helm-plugin/integration-tests/cypress.json
- packages/gitops-plugin/integration-tests /cypress.json
- packages/knative-plugin/integration-tests/cypress.json
- packages/pipelines-plugin/integration-tests /cypress.json
- packages/shipwright-plugin/integration-tests/cypress.json
- packages/webterminal-plugin/integration-tests/cypress.json
- packages/ceph-storage-plugin/integration-tests-cypress/cypress-ceph.json
- The tests run significantly faster in Cypress >= 10.x. This exposes an issue with tests that use `cy.visit` where the console redirects to `/` if the console isn't fully loaded before Cypress starts testing. A workaround is to visit `/` first and then check the perspective is set to `Administrator`. This appears to give the console time to fully load. Robb made these adjustments for `packages/integration-tests-cypress` and `packages/operator-lifecycle-manager/integration-tests-cypress` via global command (`cy.initAdmin`) he added.
- Robb also added `cy.createProjectWithCLI` and `cy.deleteProjectWithCLI` in order to reduce the run time of the tests. See https://issues.redhat.com/browse/CONSOLE-3718
AC:
- Update Cypress package in the console to version 12.17.4
- Disable all the static plugin's tests, which are not owned by OCP console team
- packages/topology/integration-tests/cypress.json
- packages/dev-console/integration-tests/cypress.json
- packages/helm-plugin/integration-tests/cypress.json
- packages/gitops-plugin/integration-tests /cypress.json
- packages/knative-plugin/integration-tests/cypress.json
- packages/pipelines-plugin/integration-tests /cypress.json
- packages/shipwright-plugin/integration-tests/cypress.json
- packages/webterminal-plugin/integration-tests/cypress.json
- packages/ceph-storage-plugin/integration-tests-cypress/cypress-ceph.json
- blocks
-
CONSOLE-3741 Upgrade Cypress to latest version
- Closed
-
CONSOLE-3742 Consider switching Cypress from Chrome to Electron
- Closed
- split from
-
CONSOLE-3716 Determine upgrade strategy for Cypress v12
- Closed
- links to
(4 links to)