This feature is under experiment.
Cytorus relies on sorry-cypress to run tests in parallel. Hence, cy2 must be added as dependency in your project.
cd cytorus-repo
npm install cy2
export CYPRESS_API_URL="http://localhost:1234/"
npx cytorus run -p true
Also set "projectId"
in cypress.json.
Remember to run sorry-cypress director before you start tests using following command
docker run -d --rm -p 1234:1234 agoldis/sorry-cypress-director:2.0.0-beta.12
-d: to run docker container in background -rm: remove container on exit
Note that the host and port are matching with CYPRESS_API_URL
.
💡 You can pull docker image in advance on the machine used to run tests in CI/CD pipelines to reduce runtime
If you're running the Cytorus locally, you may not want to run tests in parallel. In this case, you can avoid running sorry-cypress director. But ensure that you're not setting CYPRESS_API_URL
.
unset CYPRESS_API_URL
Controlling number of parallel runs
Either you can set Cytorus to run multiple instances in the same window using -p true
or open multiple CLI windows and run Cytorus using --cy2
argument.
- Please ensure that you're running sorry-cypress-director:2.0.0-beta.12 or higher
- If you're not running sorry-cypress director, don't run tests in parallel.
- If you're not running sorry-cypress director, don't set CYPRESS_API_URL env variable