Skip to content

Commit 3717f7c

Browse files
amirrustamhaoqunjiang
authored andcommitted
feat(plugin)!: update cypress plugin to reflect cross-browser capabilities
chore(plugin): add link to cypress cross-browser guide chore(dep): upgrade to cypress v4.0.0 chore(dep): upgrade to Cypress 4.0.1 chore(dep): upgrade to cypress v5.0.0
1 parent 36e500d commit 3717f7c

File tree

4 files changed

+278
-299
lines changed

4 files changed

+278
-299
lines changed

packages/@vue/cli-plugin-e2e-cypress/README.md

+4-2
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,17 @@
44
55
This adds E2E testing support using [Cypress](https://www.cypress.io/).
66

7-
Cypress offers a rich interactive interface for running E2E tests, but currently only supports running the tests in Chromium. If you have a hard requirement on E2E testing in multiple browsers, consider using the Selenium-based [@vue/cli-plugin-e2e-nightwatch](https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-e2e-nightwatch).
7+
Cypress offers a rich interactive interface for running E2E tests in Firefox and Chromium based browsers (Chrome, MS Edge, Brave, Electron). To learn more about cross browser testing, visit the [Cypress Cross Browser Testing Guide](https://on.cypress.io/cross-browser-testing).
8+
9+
> **Note:** If you have a hard requirement on E2E testing in IE or Safari, consider using the Selenium-based [@vue/cli-plugin-e2e-nightwatch](https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-e2e-nightwatch).
810
911
## Injected Commands
1012

1113
- **`vue-cli-service test:e2e`**
1214

1315
Run e2e tests with `cypress run`.
1416

15-
By default it launches Cypress in interactive mode with a GUI. If you want to run the tests in headless mode (e.g. for CI), you can do so with the `--headless` option.
17+
By default it launches Cypress in interactive mode with a GUI (via `cypress open`). If you want to run the tests in headless mode (e.g. for CI), you can do so with the `--headless` option.
1618

1719
The command automatically starts a server in production mode to run the e2e tests against. If you want to run the tests multiple times without having to restart the server every time, you can start the server with `vue-cli-service serve --mode production` in one terminal, and then run e2e tests against that server using the `--url` option.
1820

packages/@vue/cli-plugin-e2e-cypress/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
},
2525
"dependencies": {
2626
"@vue/cli-shared-utils": "^4.5.5",
27-
"cypress": "^3.8.3",
27+
"cypress": "^4.0.1",
2828
"eslint-plugin-cypress": "^2.10.3"
2929
},
3030
"peerDependencies": {

packages/@vue/cli/lib/promptModules/e2e.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ module.exports = cli => {
1717
message: 'Pick an E2E testing solution:',
1818
choices: [
1919
{
20-
name: 'Cypress (Chrome only)',
20+
name: 'Cypress (Test in Chrome, Firefox, MS Edge, and Electron)',
2121
value: 'cypress',
2222
short: 'Cypress'
2323
},

0 commit comments

Comments
 (0)