Skip to content
This repository has been archived by the owner on Sep 1, 2024. It is now read-only.

Commit

Permalink
[cypress] Use Microsoft Edge for Windows integration tests
Browse files Browse the repository at this point in the history
Chrome is slow on Windows, and Electron fails randomly with opaque
errors.
  • Loading branch information
ramosbugs committed Jul 2, 2023
1 parent 9bc5c47 commit 0f24a24
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
9 changes: 6 additions & 3 deletions packages/cypress-plugin/test/integration/src/parse-output.ts
Original file line number Diff line number Diff line change
Expand Up @@ -207,9 +207,12 @@ const parseRunStarting = (

expect(tableEntries["Cypress"]).toMatch(/^[0-9]+\.[0-9]+\.[0-9]+$/);
expect(tableEntries["Browser"]).toMatch(
// Electron is much faster on Windows than Chrome, and only a tiny bit slower on Linux, so we
// just use it for all the integration tests.
/^Electron [0-9]+ \x1B\[90m\(headless\)\x1B\[39m$/
new RegExp(
`^${
// Chrome is slow to launch on Windows.
process.platform === "win32" ? "Edge" : "Chrome"
} [0-9]+ \x1B\\[90m\\(headless\\)\x1B\\[39m$`
)
);
expect(tableEntries["Node Version"]).toMatch(
new RegExp(
Expand Down
3 changes: 3 additions & 0 deletions packages/cypress-plugin/test/integration/src/run-test-case.ts
Original file line number Diff line number Diff line change
Expand Up @@ -835,6 +835,9 @@ export const runTestCase = async (
"--",
// e2e/component
`--${params.testMode}`,
// Chrome is faster than Electron, at least on Mac. However, it's much slower on Windows.
"--browser",
process.platform === "win32" ? "edge" : "chrome",
...(params.specNameStubs !== undefined
? [
"--spec",
Expand Down

0 comments on commit 0f24a24

Please sign in to comment.