Cypress · Middle · Question 38 of 77
How do you run Cypress tests against different environments?
- 1Edit URLs in each spec before every run
- 2Copy the spec files into a folder per environment
- 3Override
baseUrland env values via config files or CLI
Show the answer
Correct answer: Override baseUrl and env values via config files or CLI
Explanation
--config baseUrl=..., --env or CYPRESS_ variables let one suite run against local, staging and preview deployments.