Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow choice of node-version with cypress/run job #475

Closed
MikeMcC399 opened this issue Jul 16, 2024 · 1 comment
Closed

Allow choice of node-version with cypress/run job #475

MikeMcC399 opened this issue Jul 16, 2024 · 1 comment
Labels
type: enhancement New feature or request

Comments

@MikeMcC399
Copy link
Collaborator

MikeMcC399 commented Jul 16, 2024

What would you like?

Add a parameter node-version to the job cypress/run to allow selection of a Node.js release or describe how to set the Node.js version without needing an extra parameter.

Why is this needed?

cypress/run provides a convenient way to run Cypress tests. It is essential to be able to specify which version of Node.js is used. Many npm modules, which are configured together with Cypress tests, have exact restrictions on which Node.js versions they may be run with. The default executor defined by the Cypress CircleCI Orb may not work:

default: "18.16.1"

Other

related to issues

According to the example, node-version is available for use with the command cypress/run-tests and is not mentioned for use with the job cypress/run:

description: >
Run Cypress tests using the cypress/default executor with a specified node version.
usage:
version: 2.1
orbs:
cypress: cypress-io/cypress@3
jobs:
run-cypress-in-specified-node-version:
executor:
name: cypress/default
node-version: "20.6"
steps:
- cypress/install:
package-manager: "yarn"
- cypress/run-tests:
start-command: "npm run start:dev"
cypress-command: "npx cypress run"
workflows:
use-my-orb:
jobs:
- run-cypress-in-specified-node-version:
name: Run Cypress in Node 20

@MikeMcC399
Copy link
Collaborator Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants