Cypress · Middle · Question 38 of 77

How do you run Cypress tests against different environments?

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.

Further reading

Problem with a question

Cypress · Middle · question 38

Test yourself

Take the Cypress · Middle quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz