-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
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
Cypress --browser option is not functional #3837
Comments
lachiesainsbury
changed the title
Cypress CLI --browser option is not functional
Cypress --browser option is not functional
Apr 17, 2019
@lachiesainsbury Cypress does not support chrome in headless mode for now. |
It looks like cypress does now support running Chrome headless, and in fact, running |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Version
3.6.3
Reproduction link
https://github.com/lachiesainsbury/cypress-browser-chrome
Environment info
Steps to reproduce
In root directory:
npm install
npm run test:e2e
What is expected?
The
test.js
test should run in a chrome browser (as specified by the--browser chrome
option in package.json).What is actually happening?
The local server starts up but the test is not being run, and no error/log information is printed to console.
I believe this is due to a cypress bug where you can't change the baseUrl property of the
--config
option whilst using the--browser chrome
option.See:
cypress-io/cypress#2518
We can work around this in cypress by specifying the baseUrl in
cypress.json
, and not using the--config baseUrl
option. The problem here is thatcli-plugin-e2e-cypress
always uses the--config
option with the baseUrl set to the server url (see). If you specify the baseUrl incypress.json
and then comment out the default baseUrl option inindex.js
, then the test runs as expected.e.g.
This isn't a huge issue if using the GUI, as you can simply select which browser to use, but I want to run cypress in headless mode with the chrome browser.
e.g.
The text was updated successfully, but these errors were encountered: