diff --git a/.circleci/config.yml b/.circleci/config.yml index 7e4f7cca19e2..81f6beaae83c 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -47,6 +47,7 @@ linuxArm64WorkflowFilters: &linux-arm64-workflow-filters when: or: - equal: [ develop, << pipeline.git.branch >> ] + - equal: [ 'webkit-multidomain', << pipeline.git.branch >> ] - equal: [ 'issue-23843_electron_21_upgrade', << pipeline.git.branch >> ] - matches: pattern: "-release$" @@ -1856,7 +1857,7 @@ jobs: name: Build command: yarn workspace @cypress/mount-utils build - store-npm-logs - + npm-xpath: <<: *defaults resource_class: small @@ -2437,11 +2438,10 @@ linux-x64-workflow: &linux-x64-workflow context: test-runner:cypress-record-key requires: - build - # TODO: Implement WebKit network automation to fix the majority of these tests before re-enabling - # - driver-integration-tests-webkit-experimentalSessionAndOrigin: - # context: test-runner:cypress-record-key - # requires: - # - build + - driver-integration-tests-webkit-experimentalSessionAndOrigin: + context: test-runner:cypress-record-key + requires: + - build - run-frontend-shared-component-tests-chrome: context: [test-runner:cypress-record-key, test-runner:launchpad-tests, test-runner:percy] percy: true diff --git a/cli/__snapshots__/build_spec.js b/cli/__snapshots__/build_spec.js index 4be1b245a7e9..e269a15e3179 100644 --- a/cli/__snapshots__/build_spec.js +++ b/cli/__snapshots__/build_spec.js @@ -3,7 +3,7 @@ exports['package.json build outputs expected properties 1'] = { "engines": "test engines", "version": "x.y.z", "buildInfo": "replaced by normalizePackageJson", - "description": "Cypress.io end to end testing tool", + "description": "Cypress is a next generation front end testing tool built for the modern web", "homepage": "https://github.com/cypress-io/cypress", "license": "MIT", "bugs": { @@ -21,6 +21,7 @@ exports['package.json build outputs expected properties 1'] = { "e2e", "end-to-end", "integration", + "component", "mocks", "runner", "spies", diff --git a/cli/types/cypress-npm-api.d.ts b/cli/types/cypress-npm-api.d.ts index 269889d6ffd0..126f50202863 100644 --- a/cli/types/cypress-npm-api.d.ts +++ b/cli/types/cypress-npm-api.d.ts @@ -60,7 +60,7 @@ declare namespace CypressCommandLine { */ headless: boolean /** - * Specify your secret record key + * Specify your secret Record Key */ key: string /** diff --git a/guides/release-process.md b/guides/release-process.md index dd309fea4c96..debf1b71bfc3 100644 --- a/guides/release-process.md +++ b/guides/release-process.md @@ -82,7 +82,7 @@ In the following instructions, "X.Y.Z" is used to denote the [next version of Cy - Go into a project, run a quick test, make sure things look right - Optionally, install the new version into an established project and run the tests there - [cypress-realworld-app](https://github.com/cypress-io/cypress-realworld-app) uses yarn and represents a typical consumer implementation. - - Optionally, do more thorough tests, for example test the new version of Cypress against the Cypress dashboard repo. + - Optionally, do more thorough tests, for example test the new version of Cypress against the Cypress Dashboard repo. 5. Log into AWS SSO with `aws sso login --profile `. If you have setup your credentials under a different profile than `prod`, be sure to set the `AWS_PROFILE` environment variable to that profile name for the remaining steps. For example, if you are using `production` instead of `prod`, do `export AWS_PROFILE=production`. @@ -119,7 +119,7 @@ In the following instructions, "X.Y.Z" is used to denote the [next version of Cy - Go into a project, run a quick test, make sure things look right - Install the new version into an established project and run the tests there - [cypress-realworld-app](https://github.com/cypress-io/cypress-realworld-app) uses yarn and represents a typical consumer implementation. - - Optionally, do more thorough tests, for example test the new version of Cypress against the Cypress dashboard repo. + - Optionally, do more thorough tests, for example test the new version of Cypress against the Cypress Dashboard repo. 11. Create or review the release-specific documentation and changelog in [cypress-documentation](https://github.com/cypress-io/cypress-documentation). If there is not already a release-specific PR open, create one. This PR must be merged, built, and deployed before moving to the next step. - Use [`release-automations`](https://github.com/cypress-io/release-automations)'s `issues-in-release` tool to generate a starting point for the changelog, based off of ZenHub: diff --git a/npm/cypress-schematic/CHANGELOG.md b/npm/cypress-schematic/CHANGELOG.md index 39f54a76c98d..4ee0261e448a 100644 --- a/npm/cypress-schematic/CHANGELOG.md +++ b/npm/cypress-schematic/CHANGELOG.md @@ -1,156 +1,14 @@ -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-10-11) +# [@cypress/schematic-v2.2.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.1.1...@cypress/schematic-v2.2.0) (2022-10-13) ### Bug Fixes -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) -* Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) - - -### Features - -* _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) - -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-10-11) - - -### Bug Fixes - -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) -* Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) - - -### Features - -* _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) - -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-10-06) - - -### Bug Fixes - -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) -* Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) - - -### Features - -* _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) - -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-10-04) - - -### Bug Fixes - -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) -* Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) - - -### Features - -* _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) - -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-10-04) - - -### Bug Fixes - -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) -* Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) - - -### Features - -* _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) - -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-10-03) - - -### Bug Fixes - -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) * Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) ### Features * _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) - -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-10-01) - - -### Bug Fixes - -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) -* Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) - - -### Features - -* _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) - -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-09-30) - - -### Bug Fixes - -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) -* Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) - - -### Features - -* _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) - -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-09-30) - - -### Bug Fixes - -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) -* Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) - - -### Features - -* _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) - -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-09-30) - - -### Bug Fixes - -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) -* Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) - - -### Features - -* _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) - -# [@cypress/schematic-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.0.3...@cypress/schematic-v2.1.0) (2022-09-29) - - -### Bug Fixes - -* angular 14.2 mount compilation error ([#23593](https://github.com/cypress-io/cypress/issues/23593)) ([2f337db](https://github.com/cypress-io/cypress/commit/2f337dbfa2bb212754c8fa82e3f4548a2f3a07a4)) -* Detect user-configured browsers ([#23446](https://github.com/cypress-io/cypress/issues/23446)) ([a75d3ec](https://github.com/cypress-io/cypress/commit/a75d3ec81f3405db6721a89875d89cdca0109013)) - - -### Features - -* _addQuery() ([#23665](https://github.com/cypress-io/cypress/issues/23665)) ([41fc535](https://github.com/cypress-io/cypress/commit/41fc535dca51cda4e40b5d9fc827d8bff534f3d1)) -* **cypress/schematic:** add support for component testing ([#23385](https://github.com/cypress-io/cypress/issues/23385)) ([99562af](https://github.com/cypress-io/cypress/commit/99562af65a10abb0fab211fd97b13f98e2b0f959)) # [@cypress/schematic-v2.1.1](https://github.com/cypress-io/cypress/compare/@cypress/schematic-v2.1.0...@cypress/schematic-v2.1.1) (2022-08-31) diff --git a/npm/mount-utils/CHANGELOG.md b/npm/mount-utils/CHANGELOG.md index 526b5725ea4b..4dab067c7bb4 100644 --- a/npm/mount-utils/CHANGELOG.md +++ b/npm/mount-utils/CHANGELOG.md @@ -1,80 +1,3 @@ -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-10-11) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-10-11) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-10-06) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-10-04) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-10-04) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-10-03) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-10-01) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-09-30) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-09-30) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-09-30) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-09-29) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - # [@cypress/mount-utils-v2.1.0](https://github.com/cypress-io/cypress/compare/@cypress/mount-utils-v2.0.1...@cypress/mount-utils-v2.1.0) (2022-08-30) diff --git a/npm/react/CHANGELOG.md b/npm/react/CHANGELOG.md index d826b7d7d0ca..c5457e9baeb4 100644 --- a/npm/react/CHANGELOG.md +++ b/npm/react/CHANGELOG.md @@ -1,80 +1,3 @@ -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-10-11) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-10-11) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-10-06) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-10-04) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-10-04) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-10-03) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-10-01) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-09-30) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-09-30) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-09-30) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-09-29) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - # [@cypress/react-v6.2.0](https://github.com/cypress-io/cypress/compare/@cypress/react-v6.1.1...@cypress/react-v6.2.0) (2022-08-30) diff --git a/npm/react18/CHANGELOG.md b/npm/react18/CHANGELOG.md index b61d0f961cfe..33113627f9aa 100644 --- a/npm/react18/CHANGELOG.md +++ b/npm/react18/CHANGELOG.md @@ -1,135 +1,10 @@ -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-10-11) +# [@cypress/react18-v1.1.1](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.1.0...@cypress/react18-v1.1.1) (2022-10-13) ### Bug Fixes * cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-10-11) - - -### Bug Fixes - -* cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-10-06) - - -### Bug Fixes - -* cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-10-04) - - -### Bug Fixes - -* cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-10-04) - - -### Bug Fixes - -* cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-10-03) - - -### Bug Fixes - -* cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-10-01) - - -### Bug Fixes - -* cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-09-30) - - -### Bug Fixes - -* cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-09-30) - - -### Bug Fixes - -* cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-09-30) - - -### Bug Fixes - -* cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-09-29) - - -### Bug Fixes - -* cypress/react18 rerender ([#23360](https://github.com/cypress-io/cypress/issues/23360)) ([8b8f20e](https://github.com/cypress-io/cypress/commit/8b8f20eec77d4c0a704aee7f7077dc92dbafb93f)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - # [@cypress/react18-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/react18-v1.0.1...@cypress/react18-v1.1.0) (2022-08-30) diff --git a/npm/vue/CHANGELOG.md b/npm/vue/CHANGELOG.md index d67bcea96010..902bf4e33d1d 100644 --- a/npm/vue/CHANGELOG.md +++ b/npm/vue/CHANGELOG.md @@ -1,4 +1,4 @@ -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-10-11) +# [@cypress/vue-v4.2.1](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.2.0...@cypress/vue-v4.2.1) (2022-10-13) ### Bug Fixes @@ -6,141 +6,6 @@ * fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) * **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-10-11) - - -### Bug Fixes - -* fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) -* **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-10-06) - - -### Bug Fixes - -* fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) -* **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-10-04) - - -### Bug Fixes - -* fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) -* **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-10-04) - - -### Bug Fixes - -* fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) -* **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-10-03) - - -### Bug Fixes - -* fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) -* **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-10-01) - - -### Bug Fixes - -* fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) -* **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-09-30) - - -### Bug Fixes - -* fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) -* **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-09-30) - - -### Bug Fixes - -* fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) -* **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-09-30) - - -### Bug Fixes - -* fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) -* **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-09-29) - - -### Bug Fixes - -* fix regression in npm/vue ([#23954](https://github.com/cypress-io/cypress/issues/23954)) ([78779a2](https://github.com/cypress-io/cypress/commit/78779a2db13ca6555a6b830dbabeefd3d37bbfe5)) -* **npm/vue:** update types ([#23890](https://github.com/cypress-io/cypress/issues/23890)) ([eb8ae02](https://github.com/cypress-io/cypress/commit/eb8ae02b61304d034136f7627da1ab23537e3ba4)) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - # [@cypress/vue-v4.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vue-v4.1.0...@cypress/vue-v4.2.0) (2022-08-30) diff --git a/npm/vue/src/index.ts b/npm/vue/src/index.ts index 49767e22d140..019b340cc075 100644 --- a/npm/vue/src/index.ts +++ b/npm/vue/src/index.ts @@ -383,8 +383,8 @@ export function mount (componentOptions: any, options: any = {}) { } /** - * Extract the compoennt name from the object passed to mount - * @param componentOptions the compoennt passed to mount + * Extract the component name from the object passed to mount + * @param componentOptions the component passed to mount * @returns name of the component */ function getComponentDisplayName (componentOptions: any): string { diff --git a/npm/vue2/CHANGELOG.md b/npm/vue2/CHANGELOG.md index ad1c28d3be10..738f7e4aca2c 100644 --- a/npm/vue2/CHANGELOG.md +++ b/npm/vue2/CHANGELOG.md @@ -1,4 +1,4 @@ -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-10-11) +# [@cypress/vue2-v1.1.1](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.1.0...@cypress/vue2-v1.1.1) (2022-10-13) ### Bug Fixes @@ -6,80 +6,6 @@ * angular and nuxt ct tests now fail on uncaught exceptions ([#24122](https://github.com/cypress-io/cypress/issues/24122)) ([53eef4f](https://github.com/cypress-io/cypress/commit/53eef4fbd7e1caf32f0183cadbc0e4cf05524c34)) -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-10-11) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-10-06) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-10-04) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-10-04) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-10-03) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-10-01) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-09-30) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-09-30) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-09-30) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - -# [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-09-29) - - -### Features - -* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) - # [@cypress/vue2-v1.1.0](https://github.com/cypress-io/cypress/compare/@cypress/vue2-v1.0.2...@cypress/vue2-v1.1.0) (2022-08-30) diff --git a/npm/webpack-dev-server/CHANGELOG.md b/npm/webpack-dev-server/CHANGELOG.md index 4b8835e8e396..d29af00484ef 100644 --- a/npm/webpack-dev-server/CHANGELOG.md +++ b/npm/webpack-dev-server/CHANGELOG.md @@ -1,3 +1,43 @@ +# [@cypress/webpack-dev-server-v2.4.0](https://github.com/cypress-io/cypress/compare/@cypress/webpack-dev-server-v2.3.0...@cypress/webpack-dev-server-v2.4.0) (2022-10-13) + + +### Bug Fixes + +* allow asynchronous vue cli init phase ([#23936](https://github.com/cypress-io/cypress/issues/23936)) ([6a40936](https://github.com/cypress-io/cypress/commit/6a40936604ae24b0b40996692c4a03e5a3c1c9a2)) +* **angular:** set webpack base so angular assets load ([#24106](https://github.com/cypress-io/cypress/issues/24106)) ([c186783](https://github.com/cypress-io/cypress/commit/c18678381ca3ab35c4ab91fdf98b5c8cf537bd21)) +* CSS import in CT Support file is not working ([#24117](https://github.com/cypress-io/cypress/issues/24117)) ([5af6b27](https://github.com/cypress-io/cypress/commit/5af6b27ed972ba9bc03d4a7fa4eaaeb2c7848fc3)) +* force Webpack to emit assets on error ([#23844](https://github.com/cypress-io/cypress/issues/23844)) ([466be9f](https://github.com/cypress-io/cypress/commit/466be9f1f0cbb843684361a9900832814353e3c0)) +* support type: module in Node.js 16.17.0+ and 18.6.0+ ([#23637](https://github.com/cypress-io/cypress/issues/23637)) ([b6dad0a](https://github.com/cypress-io/cypress/commit/b6dad0a674279936a9816939963bbf129647cee7)) +* **webpack-dev-server:** handle polyfills array for upcoming angular 15 change ([#24064](https://github.com/cypress-io/cypress/issues/24064)) ([0976034](https://github.com/cypress-io/cypress/commit/097603422535f88aed56b651824d0a3a9d5e81ff)) + + +### Features + +* allow vite/webpack config to be an async function ([#23605](https://github.com/cypress-io/cypress/issues/23605)) ([4c647f6](https://github.com/cypress-io/cypress/commit/4c647f6d5b0f58a797b50436e63c645418bc07ac)) +* CT stack traces ([#23916](https://github.com/cypress-io/cypress/issues/23916)) ([bf590eb](https://github.com/cypress-io/cypress/commit/bf590eba3f1cf46b04f6a1252e51da5c5a3dc7c2)) +* Disable file watching in component tests in run mode ([#24097](https://github.com/cypress-io/cypress/issues/24097)) ([3e01474](https://github.com/cypress-io/cypress/commit/3e014743909b35f54b697d2a759e4a2c5b67b5b7)) + +# [@cypress/webpack-dev-server-v2.3.0](https://github.com/cypress-io/cypress/compare/@cypress/webpack-dev-server-v2.2.0...@cypress/webpack-dev-server-v2.3.0) (2022-10-12) + + +### Bug Fixes + +* allow asynchronous vue cli init phase ([#23936](https://github.com/cypress-io/cypress/issues/23936)) ([6a40936](https://github.com/cypress-io/cypress/commit/6a40936604ae24b0b40996692c4a03e5a3c1c9a2)) +* **angular:** set webpack base so angular assets load ([#24106](https://github.com/cypress-io/cypress/issues/24106)) ([c186783](https://github.com/cypress-io/cypress/commit/c18678381ca3ab35c4ab91fdf98b5c8cf537bd21)) +* CSS import in CT Support file is not working ([#24117](https://github.com/cypress-io/cypress/issues/24117)) ([5af6b27](https://github.com/cypress-io/cypress/commit/5af6b27ed972ba9bc03d4a7fa4eaaeb2c7848fc3)) +* force Webpack to emit assets on error ([#23844](https://github.com/cypress-io/cypress/issues/23844)) ([466be9f](https://github.com/cypress-io/cypress/commit/466be9f1f0cbb843684361a9900832814353e3c0)) +* support type: module in Node.js 16.17.0+ and 18.6.0+ ([#23637](https://github.com/cypress-io/cypress/issues/23637)) ([b6dad0a](https://github.com/cypress-io/cypress/commit/b6dad0a674279936a9816939963bbf129647cee7)) +* **webpack-dev-server:** add custom project config to handler ([a07a2a1](https://github.com/cypress-io/cypress/commit/a07a2a118d7b62b90e790ef475c86959ae894b3b)) +* **webpack-dev-server:** handle polyfills array for upcoming angular 15 change ([#24064](https://github.com/cypress-io/cypress/issues/24064)) ([0976034](https://github.com/cypress-io/cypress/commit/097603422535f88aed56b651824d0a3a9d5e81ff)) + + +### Features + +* adding svelte component testing support ([#23553](https://github.com/cypress-io/cypress/issues/23553)) ([f6eaad4](https://github.com/cypress-io/cypress/commit/f6eaad40e1836fa9db87c60defa5ae6f390c8fd8)) +* allow vite/webpack config to be an async function ([#23605](https://github.com/cypress-io/cypress/issues/23605)) ([4c647f6](https://github.com/cypress-io/cypress/commit/4c647f6d5b0f58a797b50436e63c645418bc07ac)) +* CT stack traces ([#23916](https://github.com/cypress-io/cypress/issues/23916)) ([bf590eb](https://github.com/cypress-io/cypress/commit/bf590eba3f1cf46b04f6a1252e51da5c5a3dc7c2)) +* Disable file watching in component tests in run mode ([#24097](https://github.com/cypress-io/cypress/issues/24097)) ([3e01474](https://github.com/cypress-io/cypress/commit/3e014743909b35f54b697d2a759e4a2c5b67b5b7)) + # [@cypress/webpack-dev-server-v2.3.0](https://github.com/cypress-io/cypress/compare/@cypress/webpack-dev-server-v2.2.0...@cypress/webpack-dev-server-v2.3.0) (2022-10-11) diff --git a/npm/webpack-dev-server/cypress/e2e/angular.cy.ts b/npm/webpack-dev-server/cypress/e2e/angular.cy.ts index 2875164ecd6c..d7b499e58fec 100644 --- a/npm/webpack-dev-server/cypress/e2e/angular.cy.ts +++ b/npm/webpack-dev-server/cypress/e2e/angular.cy.ts @@ -22,7 +22,7 @@ for (const project of WEBPACK_REACT) { it('should mount a passing test', () => { cy.visitApp() cy.contains('app.component.cy.ts').click() - cy.waitForSpecToFinish({ passCount: 1 }) + cy.waitForSpecToFinish({ passCount: 1 }, 60000) cy.get('li.command').first().within(() => { cy.get('.command-method').should('contain', 'mount') @@ -33,7 +33,7 @@ for (const project of WEBPACK_REACT) { it('should live-reload on src changes', () => { cy.visitApp() cy.contains('app.component.cy.ts').click() - cy.waitForSpecToFinish({ passCount: 1 }) + cy.waitForSpecToFinish({ passCount: 1 }, 60000) cy.withCtx(async (ctx) => { await ctx.actions.file.writeFileInProject( @@ -42,7 +42,7 @@ for (const project of WEBPACK_REACT) { ) }) - cy.waitForSpecToFinish({ failCount: 1 }) + cy.waitForSpecToFinish({ failCount: 1 }, 60000) cy.withCtx(async (ctx) => { await ctx.actions.file.writeFileInProject( @@ -51,14 +51,14 @@ for (const project of WEBPACK_REACT) { ) }) - cy.waitForSpecToFinish({ passCount: 1 }) + cy.waitForSpecToFinish({ passCount: 1 }, 60000) }) it('should show compilation errors on src changes', () => { cy.visitApp() cy.contains('app.component.cy.ts').click() - cy.waitForSpecToFinish({ passCount: 1 }) + cy.waitForSpecToFinish({ passCount: 1 }, 60000) // Create compilation error cy.withCtx(async (ctx) => { @@ -71,7 +71,7 @@ for (const project of WEBPACK_REACT) { }) // The test should fail and the stack trace should appear in the command log - cy.waitForSpecToFinish({ failCount: 1 }) + cy.waitForSpecToFinish({ failCount: 1 }, 60000) cy.contains('The following error originated from your test code, not from Cypress.').should('exist') cy.get('.test-err-code-frame').should('be.visible') }) @@ -88,7 +88,7 @@ for (const project of WEBPACK_REACT) { }) cy.contains('new.component.cy.ts').click() - cy.waitForSpecToFinish({ passCount: 1 }) + cy.waitForSpecToFinish({ passCount: 1 }, 60000) }) }) } diff --git a/npm/webpack-dev-server/cypress/e2e/react.cy.ts b/npm/webpack-dev-server/cypress/e2e/react.cy.ts index 8071d1807292..310d8bfe66fc 100644 --- a/npm/webpack-dev-server/cypress/e2e/react.cy.ts +++ b/npm/webpack-dev-server/cypress/e2e/react.cy.ts @@ -131,7 +131,7 @@ for (const project of WEBPACK_REACT) { cy.findByTestId('new-spec-button').click() cy.findByRole('dialog').within(() => { cy.get('input').clear().type('src/App.cy.jsx') - cy.contains('button', 'Create Spec').click() + cy.contains('button', 'Create spec').click() }) cy.findByRole('dialog').within(() => { diff --git a/npm/webpack-dev-server/cypress/support/commands.ts b/npm/webpack-dev-server/cypress/support/commands.ts index 0c5f8317a29e..4a8d5ad4b465 100644 --- a/npm/webpack-dev-server/cypress/support/commands.ts +++ b/npm/webpack-dev-server/cypress/support/commands.ts @@ -13,7 +13,7 @@ declare global { * 3. Waits (with a timeout of 30s) for the Rerun all tests button to be present. This ensures all tests have completed * */ - waitForSpecToFinish(expectedResults?: ExpectedResults): void + waitForSpecToFinish(expectedResults?: ExpectedResults, timeout?: number): void } } } diff --git a/package.json b/package.json index 0d0824d58f9e..5bc2880accda 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "cypress", "version": "10.10.0", - "description": "Cypress.io end to end testing tool", + "description": "Cypress is a next generation front end testing tool built for the modern web", "private": true, "scripts": { "binary-build": "node ./scripts/binary.js build", @@ -238,6 +238,7 @@ "e2e", "end-to-end", "integration", + "component", "mocks", "runner", "spies", diff --git a/packages/app/README.md b/packages/app/README.md index cca5801ce754..eab9360c4b58 100644 --- a/packages/app/README.md +++ b/packages/app/README.md @@ -16,7 +16,7 @@ This is the front-end for the Cypress App. Cypress has two modes: `run` and `open`. We want run mode to be as light and fast as possible, since this is the mode used to run on CI machines, etc. Run mode has minimal UI showing only what is necessary. Open mode is the interactive experience. -- **`open`** mode is driven using GraphQL and urql. It shows the full Cypress app, include the top nav, side nav, spec list, etc. You can change between testing types, check your latest runs on the Cypress dashboard, update settings, etc. +- **`open`** mode is driven using GraphQL and urql. It shows the full Cypress app, include the top nav, side nav, spec list, etc. You can change between testing types, check your latest runs on the Cypress Dashboard, update settings, etc. - **`run`** mode is does not rely on GraphQL. This is so we can be as performant as possible. It only renders the "runner" part of the UI, which is comprised of the command log, Spec Runner header, and AUT iframe. The two modes are composed using the same logic, but have slightly different components. You can see where the differences are in `Runner.vue`(src/pages/Specs/Runner.vue). Notice that `` receives a `gql` prop, since it uses GraphQL, and `` does not. diff --git a/packages/app/cypress/e2e/create-from-component.cy.ts b/packages/app/cypress/e2e/create-from-component.cy.ts index b38809f9be53..5771917cb9b3 100644 --- a/packages/app/cypress/e2e/create-from-component.cy.ts +++ b/packages/app/cypress/e2e/create-from-component.cy.ts @@ -28,7 +28,7 @@ function validateCreateFromComponentCard (beforeEachFn: () => void, expectedSpec it('Lists Vue components in the project', () => { cy.get('@ComponentCard').click() - cy.findByText('2 Matches').should('be.visible') + cy.findByText('2 matches').should('be.visible') cy.findByText('App').should('be.visible') cy.findByText('HelloWorld').should('be.visible') @@ -38,11 +38,11 @@ function validateCreateFromComponentCard (beforeEachFn: () => void, expectedSpec cy.get('@ComponentCard').click() cy.findByText('*.vue').should('be.visible') - cy.findByText('2 Matches').should('be.visible') + cy.findByText('2 matches').should('be.visible') cy.findByLabelText('file-name-input').type('HelloWorld') cy.findByText('HelloWorld').should('be.visible') - cy.findByText('1 of 2 Matches').should('be.visible') + cy.findByText('1 of 2 matches').should('be.visible') cy.findByText('App').should('not.exist') }) @@ -105,7 +105,7 @@ describe('Create from component card', () => { cy.startAppServer('component') cy.visitApp() - cy.findByText('New Spec').click() + cy.findByText('New spec').click() cy.findAllByTestId('card').eq(0).as('ComponentCard') }, 'src/specs-folder/HelloWorld.cy.js') }) diff --git a/packages/app/cypress/e2e/cypress-in-cypress-component.cy.ts b/packages/app/cypress/e2e/cypress-in-cypress-component.cy.ts index 6bb825839dea..e196be850bfa 100644 --- a/packages/app/cypress/e2e/cypress-in-cypress-component.cy.ts +++ b/packages/app/cypress/e2e/cypress-in-cypress-component.cy.ts @@ -38,21 +38,21 @@ describe('Cypress In Cypress CT', { viewportWidth: 1500, defaultCommandTimeout: snapshotAUTPanel('cy.get selector') - cy.findByTestId('playground-num-elements').contains('1 Match') + cy.findByTestId('playground-num-elements').contains('1 match') cy.window().then((win) => cy.spy(win.console, 'log')) cy.findByTestId('playground-print').click().window().then((win) => { expect(win.console.log).to.have.been.calledWith('%cCommand: ', 'font-weight: bold', 'cy.get(\'[data-cy-root]\')') }) - cy.findByLabelText('Selector Methods').click() + cy.findByLabelText('Selector methods').click() cy.findByRole('menuitem', { name: 'cy.contains' }).click() cy.findByTestId('playground-selector').clear().type('Component Test') snapshotAUTPanel('cy.contains selector') - cy.findByTestId('playground-num-elements').contains('1 Match') + cy.findByTestId('playground-num-elements').contains('1 match') }) it('navigation between specs and other parts of the app works', () => { diff --git a/packages/app/cypress/e2e/cypress-in-cypress-e2e.cy.ts b/packages/app/cypress/e2e/cypress-in-cypress-e2e.cy.ts index c8605e3b20a3..79ef8ed39f26 100644 --- a/packages/app/cypress/e2e/cypress-in-cypress-e2e.cy.ts +++ b/packages/app/cypress/e2e/cypress-in-cypress-e2e.cy.ts @@ -45,7 +45,7 @@ describe('Cypress In Cypress E2E', { viewportWidth: 1500, defaultCommandTimeout: snapshotAUTPanel('cy.get selector') - cy.findByTestId('playground-num-elements').contains('3 Matches') + cy.findByTestId('playground-num-elements').contains('3 matches') // This validates that each matching element is covered by the playground highlighting cy.get('iframe.aut-iframe').its('0.contentDocument.body').then(cy.wrap).within(() => { @@ -59,14 +59,14 @@ describe('Cypress In Cypress E2E', { viewportWidth: 1500, defaultCommandTimeout: }) }) - cy.findByLabelText('Selector Methods').click() + cy.findByLabelText('Selector methods').click() cy.findByRole('menuitem', { name: 'cy.contains' }).click() cy.findByTestId('playground-selector').clear().type('Item 1') snapshotAUTPanel('cy.contains selector') - cy.findByTestId('playground-num-elements').contains('1 Match') + cy.findByTestId('playground-num-elements').contains('1 match') cy.window().then((win) => cy.spy(win.console, 'log')) cy.findByTestId('playground-print').click().window().then((win) => { @@ -202,7 +202,7 @@ describe('Cypress In Cypress E2E', { viewportWidth: 1500, defaultCommandTimeout: cy.contains('withFailure.spec').click() cy.contains('[aria-controls=reporter-inline-specs-list]', 'Specs') cy.get('body').type('f') - cy.contains('Search Specs') + cy.contains('Search specs') cy.contains('withWait.spec').click() cy.waitForSpecToFinish() diff --git a/packages/app/cypress/e2e/cypress-in-cypress.cy.ts b/packages/app/cypress/e2e/cypress-in-cypress.cy.ts index b958cd4785a4..2bba6f4c8c92 100644 --- a/packages/app/cypress/e2e/cypress-in-cypress.cy.ts +++ b/packages/app/cypress/e2e/cypress-in-cypress.cy.ts @@ -224,7 +224,7 @@ describe('Cypress in Cypress', { viewportWidth: 1500, defaultCommandTimeout: 100 cy.get('body').click() }) - cy.get('[data-cy="playground-num-elements"]').contains('1 Match') + cy.get('[data-cy="playground-num-elements"]').contains('1 match') }) it(`hides reporter when NO_COMMAND_LOG is set in open mode for ${testingType}`, () => { diff --git a/packages/app/cypress/e2e/runner/retries.mochaEvents.cy.ts b/packages/app/cypress/e2e/runner/retries.mochaEvents.cy.ts index bd69d0890022..e201b32afe14 100644 --- a/packages/app/cypress/e2e/runner/retries.mochaEvents.cy.ts +++ b/packages/app/cypress/e2e/runner/retries.mochaEvents.cy.ts @@ -11,7 +11,6 @@ import { snapshots } from './retries.mochaEvents.snapshots' */ describe('src/cypress/runner retries mochaEvents', { retries: 0, defaultCommandTimeout: 7500 }, () => { // NOTE: for test-retries - it('simple retry', (done) => { const { assertMatchingSnapshot } = runCypressInCypressMochaEventsTest( snapshots, diff --git a/packages/app/cypress/e2e/runner/support/mochaEventsUtils.ts b/packages/app/cypress/e2e/runner/support/mochaEventsUtils.ts index a1fc586c302c..f6ed349a2ccf 100644 --- a/packages/app/cypress/e2e/runner/support/mochaEventsUtils.ts +++ b/packages/app/cypress/e2e/runner/support/mochaEventsUtils.ts @@ -134,13 +134,6 @@ declare global { } } -class SnapshotError extends Error { - constructor (message: string) { - super() - this.message = `\n${message}` - } -} - export function runCypressInCypressMochaEventsTest (snapshots: T, snapToCompare: keyof T, done: Mocha.Done) { const bus = new EventEmitter() const outerRunner = window.top!.window @@ -157,10 +150,17 @@ export function runCypressInCypressMochaEventsTest (snapshots: T, snapToCompa if (diff !== '') { /* eslint-disable no-console */ console.info('Received snapshot:', JSON.stringify(snapshot, null, 2)) - throw new SnapshotError(diff) + + return cy.fail(new Error(`The captured mocha events did not match the "${String(snapToCompare)}" snapshot.\n${diff}`), { async: false }) } - done() + Cypress.log({ + name: 'assert', + message: `The captured mocha events for the spec matched the "${String(snapToCompare)}" snapshot!`, + state: 'passed', + }) + + return done() }) const assertMatchingSnapshot = (win: Cypress.AUTWindow) => { diff --git a/packages/app/cypress/e2e/runs.cy.ts b/packages/app/cypress/e2e/runs.cy.ts index 9a79cb4aecff..c03d84a13489 100644 --- a/packages/app/cypress/e2e/runs.cy.ts +++ b/packages/app/cypress/e2e/runs.cy.ts @@ -81,7 +81,7 @@ describe('App: Runs', { viewportWidth: 1200 }, () => { }) cy.findByRole('dialog', { name: 'Log in to Cypress' }).within(() => { - cy.contains('button', 'Log In').click() + cy.contains('button', 'Log in').click() }) cy.withCtx((ctx, o) => { @@ -272,10 +272,10 @@ describe('App: Runs', { viewportWidth: 1200 }, () => { cy.contains('button', 'Log in to the Cypress Dashboard').click() cy.findByRole('dialog', { name: 'Log in to Cypress' }).as('logInModal').within(() => { - cy.findByRole('button', { name: 'Log In' }).click() + cy.findByRole('button', { name: 'Log in' }).click() }) - cy.findByRole('dialog', { name: 'Login Successful' }).within(() => { + cy.findByRole('dialog', { name: 'Login successful' }).within(() => { cy.findByRole('button', { name: 'Connect project' }).click() }) @@ -443,7 +443,7 @@ describe('App: Runs', { viewportWidth: 1200 }, () => { cy.findByText(defaultMessages.runs.errors.notFound.button).should('be.visible').click() cy.get('[aria-modal="true"]').should('exist') cy.get('[data-cy="selectProject"] button').should('have.text', 'Mock Project') - cy.findByText(defaultMessages.runs.connect.modal.selectProject.connectProject).click() + cy.get('[data-cy="connect-project"]').click() cy.get('[data-cy="runs"]', { timeout: 7500 }) }) }) @@ -591,7 +591,7 @@ describe('App: Runs', { viewportWidth: 1200 }, () => { scaffoldTestingTypeAndVisitRunsPage('component') cy.contains(defaultMessages.runs.empty.title).should('be.visible') cy.contains(defaultMessages.runs.empty.description).should('be.visible') - cy.contains('cypress run --component --record --key 2aaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa').should('be.visible') + cy.findByDisplayValue('npx cypress run --component --record --key 2aaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa').should('be.visible') }) it('displays how to record prompt when connected and no runs in E2E', () => { @@ -599,7 +599,7 @@ describe('App: Runs', { viewportWidth: 1200 }, () => { cy.contains(defaultMessages.runs.empty.title).should('be.visible') cy.contains(defaultMessages.runs.empty.description).should('be.visible') - cy.contains('cypress run --record --key 2aaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa').should('be.visible') + cy.findByDisplayValue('npx cypress run --record --key 2aaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa').should('be.visible') }) it('displays a copy button and copies correct command in Component Testing', () => { diff --git a/packages/app/cypress/e2e/settings.cy.ts b/packages/app/cypress/e2e/settings.cy.ts index e296eda4c084..672e7cfaba25 100644 --- a/packages/app/cypress/e2e/settings.cy.ts +++ b/packages/app/cypress/e2e/settings.cy.ts @@ -17,11 +17,11 @@ describe('App: Settings', () => { cy.get(SidebarSettingsLinkSelector).click() cy.contains('[data-cy="app-header-bar"]', 'Settings') - cy.contains('[data-cy="app-header-bar"] button', 'Log In').should('be.visible') + cy.contains('[data-cy="app-header-bar"] button', 'Log in').should('be.visible') - cy.findByText('Device Settings').should('be.visible') - cy.findByText('Project Settings').should('be.visible') - cy.findByText('Dashboard Settings').should('be.visible') + cy.findByText('Device settings').should('be.visible') + cy.findByText('Project settings').should('be.visible') + cy.findByText('Dashboard settings').should('be.visible') }) describe('Cloud Settings', () => { @@ -33,7 +33,7 @@ describe('App: Settings', () => { cy.startAppServer('e2e') cy.visitApp() cy.get(SidebarSettingsLinkSelector).click() - cy.findByText('Dashboard Settings').click() + cy.findByText('Dashboard settings').click() cy.findByText('Project ID').should('be.visible') cy.get('[data-cy="code-box"]').should('contain', 'fromCli') cy.findByText('Copy').click() @@ -49,17 +49,17 @@ describe('App: Settings', () => { cy.visitApp() cy.get(SidebarSettingsLinkSelector).click() - cy.findByText('Dashboard Settings').click() - cy.findByText('Record Key').should('be.visible') + cy.findByText('Dashboard settings').click() + cy.findByText('Record key').should('be.visible') }) - it('obfuscates each record key and has a button to reveal the key', () => { + it('obfuscates each Record Key and has a button to reveal the key', () => { cy.startAppServer('e2e') cy.loginUser() cy.visitApp() cy.get(SidebarSettingsLinkSelector).click() - cy.findByText('Dashboard Settings').click() + cy.findByText('Dashboard settings').click() cy.get('[data-cy="code-box"]').should('contain', '***') cy.get('[aria-label="Record Key Visibility Toggle"]').click() cy.get('[data-cy="code-box"]').should('contain', '2aaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa') @@ -69,8 +69,8 @@ describe('App: Settings', () => { cy.startAppServer('e2e') cy.loginUser() cy.visitApp('settings') - cy.findByText('Dashboard Settings').click() - cy.findByText('Manage Keys').click() + cy.findByText('Dashboard settings').click() + cy.findByText('Manage keys').click() cy.withRetryableCtx((ctx) => { expect((ctx.actions.electron.openExternal as SinonStub).lastCall.lastArg).to.eq('http:/test.cloud/cloud-project/settings') }) @@ -97,13 +97,13 @@ describe('App: Settings', () => { // Wait for the test to pass, so the test is completed cy.get('.passed > .num').should('contain', 1) cy.get(SidebarSettingsLinkSelector).click() - cy.contains('Dashboard Settings').click() + cy.contains('Dashboard settings').click() // Assert the data is not there before it arrives - cy.contains('Record Key').should('not.exist') - cy.contains('Record Key') + cy.contains('Record key').should('not.exist') + cy.contains('Record key') }) - it('clears nested cloud data (record key) upon logging out', () => { + it('clears nested cloud data (Record Key) upon logging out', () => { cy.startAppServer('e2e') cy.loginUser() cy.visitApp() @@ -112,23 +112,23 @@ describe('App: Settings', () => { }) cy.findByTestId('sidebar-link-settings-page').click() - cy.contains('Dashboard Settings').click() - cy.contains('Record Key').should('exist') + cy.contains('Dashboard settings').click() + cy.contains('Record key').should('exist') cy.findByTestId('sidebar-link-runs-page').click() cy.findByTestId('user-avatar-title').click() - cy.findByRole('button', { name: 'Log Out' }).click() + cy.findByRole('button', { name: 'Log out' }).click() cy.withRetryableCtx((ctx, o) => { expect(ctx.actions.auth.logout).to.have.been.calledOnce }) cy.findByTestId('sidebar-link-settings-page').click() - cy.contains('Dashboard Settings').click() - cy.contains('Record Key').should('not.exist') + cy.contains('Dashboard settings').click() + cy.contains('Record key').should('not.exist') }) }) - describe('Project Settings', () => { + describe('Project settings', () => { it('shows the Spec Patterns section (default specPattern value)', () => { cy.scaffoldProject('simple-ct') cy.openProject('simple-ct') @@ -137,8 +137,8 @@ describe('App: Settings', () => { cy.visitApp() cy.findByTestId('sidebar-link-settings-page').click() - cy.findByText('Project Settings').click() - cy.get('[data-cy="file-match-indicator"]').contains('2 Matches') + cy.findByText('Project settings').click() + cy.get('[data-cy="file-match-indicator"]').contains('2 matches') cy.get('[data-cy="spec-pattern"]').contains('**/*.cy.{js,jsx,ts,tsx}') cy.get('[data-cy="settings-specPatterns"').within(() => { @@ -155,8 +155,8 @@ describe('App: Settings', () => { cy.visitApp() cy.get(SidebarSettingsLinkSelector).click() - cy.findByText('Project Settings').click() - cy.get('[data-cy="file-match-indicator"]').contains('41 Matches') + cy.findByText('Project settings').click() + cy.get('[data-cy="file-match-indicator"]').contains('41 matches') cy.get('[data-cy="spec-pattern"]').contains('tests/**/*') }) @@ -166,7 +166,7 @@ describe('App: Settings', () => { cy.visitApp() cy.get(SidebarSettingsLinkSelector).click() - cy.findByText('Project Settings').click() + cy.findByText('Project settings').click() cy.get('[data-cy="settings-experiments"]').within(() => { cy.validateExternalLink({ name: 'Learn more.', @@ -229,7 +229,7 @@ describe('App: Settings', () => { cy.visitApp() cy.get(SidebarSettingsLinkSelector).click() - cy.findByText('Project Settings').click() + cy.findByText('Project settings').click() cy.get('[data-cy="config-code"]').contains('{') }) @@ -239,7 +239,7 @@ describe('App: Settings', () => { cy.visitApp() cy.get(SidebarSettingsLinkSelector).click() - cy.findByText('Project Settings').click() + cy.findByText('Project settings').click() cy.get('[data-cy="config-legend"]').within(() => { cy.get('.bg-gray-50').contains('default') cy.get('.bg-teal-100').contains('config') @@ -267,7 +267,7 @@ describe('App: Settings', () => { }) cy.visitApp('/settings') - cy.findByText('Project Settings').click() + cy.findByText('Project settings').click() cy.findByRole('button', { name: 'Edit' }).click() cy.withRetryableCtx((ctx) => { expect((ctx.actions.file.openFile as SinonStub).lastCall.args[0]).to.eq(ctx.lifecycleManager.configFilePath) @@ -282,7 +282,7 @@ describe('App: Settings', () => { cy.visitApp() cy.get(SidebarSettingsLinkSelector).click() - cy.findByText('Project Settings').click() + cy.findByText('Project settings').click() cy.get('[data-cy="config-legend"]').within(() => { cy.get('.bg-gray-50').contains('default') cy.get('.bg-teal-100').contains('config') @@ -329,7 +329,7 @@ describe('App: Settings', () => { }) cy.visitApp('settings') - cy.contains('Device Settings').click() + cy.contains('Device settings').click() }) it('selects well known editor', () => { @@ -344,7 +344,7 @@ describe('App: Settings', () => { cy.visitApp() cy.findByTestId('sidebar-link-settings-page').click() cy.wait(200) - cy.get('[data-cy="Device Settings"]').click() + cy.get('[data-cy="Device settings"]').click() cy.get('[data-cy="custom-editor"]').should('not.exist') }) @@ -365,7 +365,7 @@ describe('App: Settings', () => { // preferred editor entered from input should have been persisted cy.findByTestId('sidebar-link-settings-page').click() cy.wait(100) - cy.get('[data-cy="Device Settings"]').click() + cy.get('[data-cy="Device settings"]').click() cy.get('[data-cy="custom-editor"]').should('have.value', '/usr/local/bin/vim') }) @@ -393,7 +393,7 @@ describe('App: Settings', () => { cy.visitApp() cy.findByTestId('sidebar-link-settings-page').click() cy.wait(200) - cy.get('[data-cy="Device Settings"]').click() + cy.get('[data-cy="Device settings"]').click() cy.get('[data-cy="custom-editor"]').should('not.exist') }) @@ -408,7 +408,7 @@ describe('App: Settings without cloud', () => { cy.visitApp() cy.get(SidebarSettingsLinkSelector).click() - cy.findByText('Dashboard Settings').click() + cy.findByText('Dashboard settings').click() cy.findByText('Project ID').should('exist') cy.withCtx((ctx, o) => { o.sinon.spy(ctx._apis.authApi, 'logIn') @@ -416,7 +416,7 @@ describe('App: Settings without cloud', () => { cy.contains('button', 'Log in to the Cypress Dashboard').click() cy.findByRole('dialog', { name: 'Log in to Cypress' }).within(() => { - cy.contains('button', 'Log In').click() + cy.contains('button', 'Log in').click() }) cy.withCtx((ctx, o) => { @@ -434,7 +434,7 @@ describe('App: Settings without cloud', () => { cy.visitApp() cy.get(SidebarSettingsLinkSelector).click() - cy.findByText('Project Settings').click() + cy.findByText('Project settings').click() cy.get('[data-cy=config-code]').within(() => { const { browsers } = Cypress.config() diff --git a/packages/app/cypress/e2e/sidebar_navigation.cy.ts b/packages/app/cypress/e2e/sidebar_navigation.cy.ts index b0d195d723b2..48d791221fb6 100644 --- a/packages/app/cypress/e2e/sidebar_navigation.cy.ts +++ b/packages/app/cypress/e2e/sidebar_navigation.cy.ts @@ -35,7 +35,7 @@ describe('Sidebar Navigation', { viewportWidth: 1280 }, () => { .should('have.attr', 'aria-label', 'Expand sidebar') cy.findByTestId('keyboard-modal-trigger') - .should('have.attr', 'aria-label', 'Keyboard Shortcuts') + .should('have.attr', 'aria-label', 'Keyboard shortcuts') cy.get('nav') .should('have.attr', 'aria-label', 'Pages') @@ -116,7 +116,7 @@ describe('Sidebar Navigation', { viewportWidth: 1280 }, () => { cy.findByTestId('sidebar').should('have.css', 'width', '64px') // assert width to ensure transition has finished cy.findByTestId('keyboard-modal-trigger').should('be.visible').click() - cy.contains('h2', 'Keyboard Shortcuts').should('be.visible') + cy.contains('h2', 'Keyboard shortcuts').should('be.visible') cy.get('li p').contains('Re-run tests').should('be.visible') cy.get('li p').contains('Stop tests').should('be.visible') cy.get('li p').contains('Toggle specs list').should('be.visible') @@ -209,7 +209,7 @@ describe('Sidebar Navigation', { viewportWidth: 1280 }, () => { it('has menu item that shows the keyboard shortcuts modal (expanded state)', () => { cy.findByTestId('keyboard-modal-trigger').should('be.visible').click() - cy.contains('h2', 'Keyboard Shortcuts').should('be.visible') + cy.contains('h2', 'Keyboard shortcuts').should('be.visible') cy.get('li p').contains('Re-run tests').should('be.visible') cy.get('li p').contains('Stop tests').should('be.visible') cy.get('li p').contains('Toggle specs list').should('be.visible') @@ -217,7 +217,7 @@ describe('Sidebar Navigation', { viewportWidth: 1280 }, () => { cy.get('li span').contains('s') cy.get('li span').contains('f') cy.get('[aria-label="Close"]').click() - cy.findByText('Keyboard Shortcuts').should('not.exist') + cy.findByText('Keyboard shortcuts').should('not.exist') }) it('has a menu item labeled "Runs" which takes you to the Runs page', () => { diff --git a/packages/app/cypress/e2e/specs.cy.ts b/packages/app/cypress/e2e/specs.cy.ts index 4838370b028a..f3ce0acb69af 100644 --- a/packages/app/cypress/e2e/specs.cy.ts +++ b/packages/app/cypress/e2e/specs.cy.ts @@ -61,7 +61,7 @@ describe('App: Specs', () => { }).should('be.visible').within(() => { cy.validateExternalLink({ name: 'Need help', href: 'https://on.cypress.io/test-type-options' }) cy.findByRole('button', { name: 'Close' }).should('be.visible').as('CloseDialogButton') - cy.get('[data-cy="file-match-indicator"]').contains('No Matches') + cy.get('[data-cy="file-match-indicator"]').contains('No matches') cy.get('[data-cy="spec-pattern"]').contains('cypress/e2e/**/*.cy.{js,jsx,ts,tsx}') }) @@ -340,12 +340,12 @@ describe('App: Specs', () => { .should('be.visible') .and('contain', defaultMessages.createSpec.page.customPatternNoSpecs.description.split('{0}')[0]) - cy.findByTestId('file-match-indicator').should('contain', 'No Matches') + cy.findByTestId('file-match-indicator').should('contain', 'No matches') cy.findByRole('button', { name: 'cypress.config.js' }) cy.findByTestId('spec-pattern').should('contain', 'src/**/*.{cy,spec}.{js,jsx}') cy.contains('button', defaultMessages.createSpec.updateSpecPattern) - cy.findByRole('button', { name: 'New Spec', exact: false }) + cy.findByRole('button', { name: 'New spec', exact: false }) }) it('opens config file in ide from SpecPattern', () => { @@ -385,7 +385,7 @@ describe('App: Specs', () => { }) it('shows new spec button to start creation workflow', () => { - cy.findByRole('button', { name: 'New Spec', exact: false }).click() + cy.findByRole('button', { name: 'New spec', exact: false }).click() cy.findByRole('dialog', { name: defaultMessages.createSpec.newSpecModalTitle }).within(() => { cy.findAllByTestId('card').eq(0) @@ -398,7 +398,7 @@ describe('App: Specs', () => { context('scaffold empty spec', () => { it('should generate empty spec', () => { - cy.findByRole('button', { name: 'New Spec', exact: false }).click() + cy.findByRole('button', { name: 'New spec', exact: false }).click() cy.findByRole('dialog', { name: defaultMessages.createSpec.newSpecModalTitle }).within(() => { cy.findAllByTestId('card').eq(0) @@ -455,9 +455,9 @@ describe('App: Specs', () => { // Timeout is increased here to allow ample time for the config change to be processed cy.contains('src/e2e/**/*.{js,jsx}', { timeout: 12000 }).should('be.visible') - cy.contains('No Specs Found').should('be.visible') + cy.contains('No specs found').should('be.visible') - cy.findByRole('button', { name: 'New Spec' }).click() + cy.findByRole('button', { name: 'New spec' }).click() cy.contains('Create new empty spec').click() cy.findAllByLabelText(defaultMessages.createSpec.e2e.importEmptySpec.inputPlaceholder) @@ -474,7 +474,7 @@ describe('App: Specs', () => { }) it('shows extension warning', () => { - cy.findByRole('button', { name: 'New Spec', exact: false }).click() + cy.findByRole('button', { name: 'New spec', exact: false }).click() cy.findByRole('dialog', { name: defaultMessages.createSpec.newSpecModalTitle }).within(() => { cy.findAllByTestId('card').eq(0) @@ -572,7 +572,7 @@ describe('App: Specs', () => { cy.findByLabelText('Enter a relative path...').clear().type('cypress/my-empty-spec.cy.js') - cy.findByRole('button', { name: 'Create Spec' }).click() + cy.findByRole('button', { name: 'Create spec' }).click() }) cy.findByRole('dialog', { @@ -598,7 +598,7 @@ describe('App: Specs', () => { cy.findByLabelText('Enter a relative path...').clear().type('cypress/my-empty-spec.cy.js') - cy.findByRole('button', { name: 'Create Spec' }).click() + cy.findByRole('button', { name: 'Create spec' }).click() }) cy.findByRole('dialog', { name: defaultMessages.createSpec.successPage.header }).within(() => { @@ -618,7 +618,7 @@ describe('App: Specs', () => { cy.findByLabelText('Enter a relative path...').clear().type('cypress/my-empty-spec.cy.js') - cy.findByRole('button', { name: 'Create Spec' }).click() + cy.findByRole('button', { name: 'Create spec' }).click() }) cy.findByRole('dialog', { name: defaultMessages.createSpec.successPage.header }).within(() => { @@ -674,12 +674,12 @@ describe('App: Specs', () => { .should('be.visible') .and('contain', defaultMessages.createSpec.page.customPatternNoSpecs.description.split('{0}')[0]) - cy.findByTestId('file-match-indicator').should('contain', 'No Matches') + cy.findByTestId('file-match-indicator').should('contain', 'No matches') cy.findByRole('button', { name: 'cypress.config.js' }) cy.findByTestId('spec-pattern').should('contain', 'src/specs-folder/*.cy.{js,jsx}') cy.contains('button', defaultMessages.createSpec.updateSpecPattern) - cy.findByRole('button', { name: 'New Spec', exact: false }) + cy.findByRole('button', { name: 'New spec', exact: false }) }) it('opens config file in ide from SpecPattern', () => { @@ -707,13 +707,13 @@ describe('App: Specs', () => { }) it('shows new spec button to start creation workflow', () => { - cy.findByRole('button', { name: 'New Spec', exact: false }).click() + cy.findByRole('button', { name: 'New spec', exact: false }).click() cy.findByRole('dialog', { name: 'Enter the path for your new spec' }).should('be.visible') }) it('shows create first spec page with create empty option and goes back if it is cancel', () => { - cy.findByRole('button', { name: 'New Spec', exact: false }).click() + cy.findByRole('button', { name: 'New spec', exact: false }).click() cy.contains('Cancel').click() @@ -734,16 +734,16 @@ describe('App: Specs', () => { // Timeout is increased here to allow ample time for the config change to be processed cy.contains('src/specs-folder/*.{js,jsx}', { timeout: 12000 }).should('be.visible') - cy.contains('No Specs Found').should('be.visible') + cy.contains('No specs found').should('be.visible') - cy.findByRole('button', { name: 'New Spec' }).click() + cy.findByRole('button', { name: 'New spec' }).click() cy.findByRole('dialog', { name: 'Enter the path for your new spec', }).within(() => { cy.findByLabelText('Enter a relative path...').invoke('val').should('eq', getPathForPlatform('src/specs-folder/ComponentName.js')) - cy.findByRole('button', { name: 'Create Spec' }).click() + cy.findByRole('button', { name: 'Create spec' }).click() }) cy.findByRole('dialog', { @@ -868,7 +868,7 @@ describe('App: Specs', () => { } }, { specs }) - cy.contains('20 Matches') + cy.contains('20 matches') cy.withRetryableCtx((ctx, o) => { // setSpecs is debounced, the number of calls should be less than the number of files removed diff --git a/packages/app/cypress/e2e/specs_list_component.cy.ts b/packages/app/cypress/e2e/specs_list_component.cy.ts index 640704b06c2f..de3f9b3163cd 100644 --- a/packages/app/cypress/e2e/specs_list_component.cy.ts +++ b/packages/app/cypress/e2e/specs_list_component.cy.ts @@ -14,7 +14,7 @@ describe('App: Spec List (Component)', () => { cy.get('[data-cy="spec-pattern-modal"]').should('be.visible') cy.get('[data-cy="spec-pattern"]').contains('cypress/component-tests/*.spec.js') - cy.contains('button', 'Update Spec Pattern').click() + cy.contains('button', 'Update spec pattern').click() cy.get('[data-cy="choose-editor-modal"]').should('be.visible').within(() => { cy.get('[aria-label="Close"]').click() }) @@ -31,7 +31,7 @@ describe('App: Spec List (Component)', () => { cy.get('[data-selected-spec="false"]').should('contain', 'foo') }) - it('opens the "Create a new spec" modal after clicking the "New Specs" button', () => { + it('opens the "Create a new spec" modal after clicking the "New specs" button', () => { cy.get('[data-cy="standard-modal"]').should('not.exist') cy.get('[data-cy="new-spec-button"]').click() cy.get('[data-cy="standard-modal"]').get('h2').contains('Enter the path for your new spec') diff --git a/packages/app/cypress/e2e/specs_list_e2e.cy.ts b/packages/app/cypress/e2e/specs_list_e2e.cy.ts index 2c778a8b6a5b..f66467d8fb2c 100644 --- a/packages/app/cypress/e2e/specs_list_e2e.cy.ts +++ b/packages/app/cypress/e2e/specs_list_e2e.cy.ts @@ -85,7 +85,7 @@ describe('App: Spec List (E2E)', () => { cy.findAllByTestId('spec-item').should('contain', 'dom-content.spec.js') }) - it('opens the "Create a new spec" modal after clicking the "New Specs" button', () => { + it('opens the "Create a new spec" modal after clicking the "New specs" button', () => { cy.findByTestId('standard-modal').should('not.exist') cy.findByTestId('new-spec-button').click() cy.findByTestId('standard-modal').get('h2').contains('Create a new spec') @@ -139,12 +139,12 @@ describe('App: Spec List (E2E)', () => { describe('typing the filter', function () { beforeEach(() => { - cy.findByLabelText('Search Specs').as('searchField') + cy.findByLabelText('Search specs').as('searchField') }) it('displays only matching spec', function () { cy.get('button') - .contains('23 Matches') + .contains('23 matches') .should('not.contain.text', 'of') clearSearchAndType('content') @@ -152,13 +152,13 @@ describe('App: Spec List (E2E)', () => { .should('have.length', 2) .and('contain', 'dom-content.spec.js') - cy.get('button').contains('2 of 23 Matches') + cy.get('button').contains('2 of 23 matches') - cy.findByLabelText('Search Specs').clear().type('asdf') + cy.findByLabelText('Search specs').clear().type('asdf') cy.findAllByTestId('spec-item') .should('have.length', 0) - cy.get('button').contains('0 of 23 Matches') + cy.get('button').contains('0 of 23 matches') }) it('only shows matching folders', () => { @@ -206,10 +206,10 @@ describe('App: Spec List (E2E)', () => { it('clears the filter on search bar clear button click', function () { clearSearchAndType('123') cy.findByLabelText('Clear search field').click() - cy.findByLabelText('Search Specs') + cy.findByLabelText('Search specs') .should('have.value', '') - cy.get('button').contains('23 Matches') + cy.get('button').contains('23 matches') }) it('clears the filter if the user presses ESC key', function () { @@ -218,7 +218,7 @@ describe('App: Spec List (E2E)', () => { cy.get('@searchField').should('have.value', '') - cy.get('button').contains('23 Matches') + cy.get('button').contains('23 matches') }) it('shows empty message if no results', function () { @@ -231,10 +231,10 @@ describe('App: Spec List (E2E)', () => { it('clears and focuses the filter field when clear search is clicked', function () { clearSearchAndType('asdf') - cy.findByText('Clear Search').click() + cy.findByText('Clear search').click() cy.focused().should('have.id', 'spec-filter') - cy.get('button').contains('23 Matches') + cy.get('button').contains('23 matches') }) it('normalizes directory path separators for Windows', function () { @@ -274,7 +274,7 @@ describe('App: Spec List (E2E)', () => { launchApp(targetSpecFile) - cy.findByLabelText('Search Specs').should('have.value', targetSpecFile) + cy.findByLabelText('Search specs').should('have.value', targetSpecFile) }) }) }) diff --git a/packages/app/cypress/e2e/specs_list_latest_runs.cy.ts b/packages/app/cypress/e2e/specs_list_latest_runs.cy.ts index e8cef2166d81..6d99a9b6a384 100644 --- a/packages/app/cypress/e2e/specs_list_latest_runs.cy.ts +++ b/packages/app/cypress/e2e/specs_list_latest_runs.cy.ts @@ -208,7 +208,7 @@ describe('App/Cloud Integration - Latest runs and Average duration', { viewportW .click() cy.findByRole('dialog', { name: 'Log in to Cypress' }).within(() => { - cy.get('button').contains('Log In') + cy.get('button').contains('Log in') cy.get('[aria-label="Close"]').click() }) @@ -222,7 +222,7 @@ describe('App/Cloud Integration - Latest runs and Average duration', { viewportW .click() cy.findByRole('dialog', { name: 'Log in to Cypress' }).within(() => { - cy.get('button').contains('Log In') + cy.get('button').contains('Log in') cy.get('[aria-label="Close"]').click() }) @@ -405,7 +405,7 @@ describe('App/Cloud Integration - Latest runs and Average duration', { viewportW .should('have.attr', 'aria-expanded', 'false') .then((dir) => { // Perform a search/filter operation - cy.findByLabelText('Search Specs').type(dir.text()[0]) + cy.findByLabelText('Search specs').type(dir.text()[0]) }) // Previously-collapsed directory should automatically expand @@ -422,7 +422,7 @@ describe('App/Cloud Integration - Latest runs and Average duration', { viewportW // Move to Settings page and wait for render cy.get('a[href="#/settings"]').click() cy.location('hash').should('include', '/settings') - cy.findByText('Project Settings').should('be.visible') + cy.findByText('Project settings').should('be.visible') // Move back to Specs page and wait for render cy.get('a[href="#/specs"]').click() diff --git a/packages/app/cypress/e2e/subscriptions/authChange-subscription.cy.ts b/packages/app/cypress/e2e/subscriptions/authChange-subscription.cy.ts index acbfa8274f87..568b738f8d59 100644 --- a/packages/app/cypress/e2e/subscriptions/authChange-subscription.cy.ts +++ b/packages/app/cypress/e2e/subscriptions/authChange-subscription.cy.ts @@ -30,7 +30,7 @@ describe('authChange subscription', () => { }) it('responds to authChange subscription for login', () => { - cy.contains('Log In') + cy.contains('Log in') cy.wait(500) cy.withCtx(async (ctx) => { await ctx.actions.auth.login('testing', 'testing') @@ -48,7 +48,7 @@ describe('authChange subscription', () => { await ctx.actions.auth.logout() }) - cy.contains('Log In') + cy.contains('Log in') }) }) @@ -59,7 +59,7 @@ describe('authChange subscription', () => { }) it('responds to authChange subscription for login', () => { - cy.contains('Log In') + cy.contains('Log in') cy.wait(500) cy.withCtx(async (ctx) => { await ctx.actions.auth.login('testing', 'testing') @@ -77,7 +77,7 @@ describe('authChange subscription', () => { await ctx.actions.auth.logout() }) - cy.contains('Log In') + cy.contains('Log in') }) }) @@ -87,7 +87,7 @@ describe('authChange subscription', () => { }) it('responds to authChange subscription for login', () => { - cy.contains('Log In') + cy.contains('Log in') cy.wait(500) cy.withCtx(async (ctx) => { await ctx.actions.auth.login('testing', 'testing') @@ -105,7 +105,7 @@ describe('authChange subscription', () => { await ctx.actions.auth.logout() }) - cy.contains('Log In') + cy.contains('Log in') }) }) }) diff --git a/packages/app/cypress/e2e/subscriptions/configChange-subscription.cy.ts b/packages/app/cypress/e2e/subscriptions/configChange-subscription.cy.ts index e9b895362a1d..2a26713d8798 100644 --- a/packages/app/cypress/e2e/subscriptions/configChange-subscription.cy.ts +++ b/packages/app/cypress/e2e/subscriptions/configChange-subscription.cy.ts @@ -27,7 +27,7 @@ describe('configChange subscription', () => { describe('on config page', () => { it('responds to configChange event when viewport is changed', () => { cy.contains('a', 'Settings').click() - cy.get('[data-cy="collapsible-header"]').contains('Project Settings').click() + cy.get('[data-cy="collapsible-header"]').contains('Project settings').click() cy.contains(`projectId: 'abc123'`) updateProjectIdInCypressConfig('foo456') cy.contains(`projectId: 'foo456'`) diff --git a/packages/app/cypress/e2e/subscriptions/specChange-subscription.cy.ts b/packages/app/cypress/e2e/subscriptions/specChange-subscription.cy.ts index 4d344397ca03..2a0318bc6368 100644 --- a/packages/app/cypress/e2e/subscriptions/specChange-subscription.cy.ts +++ b/packages/app/cypress/e2e/subscriptions/specChange-subscription.cy.ts @@ -324,14 +324,14 @@ e2e: { cy.get('[data-cy="spec-pattern"]').contains('cypress/e2e/**/*.spec.{js,ts}') cy.get('[data-cy="file-match-indicator"]') - .should('contain', '23 Matches') + .should('contain', '23 matches') cy.withCtx(async (ctx, o) => { await ctx.actions.file.writeFileInProject(o.path, '') }, { path: getPathForPlatform('cypress/e2e/new-file.spec.js') }) cy.get('[data-cy="file-match-indicator"]') - .should('contain', '24 Matches') + .should('contain', '24 matches') }) it('responds to specChange event for a removed file', () => { @@ -341,14 +341,14 @@ e2e: { cy.get('[data-cy="spec-pattern"]').contains('cypress/e2e/**/*.spec.{js,ts}') cy.get('[data-cy="file-match-indicator"]') - .should('contain', '23 Matches') + .should('contain', '23 matches') cy.withCtx(async (ctx, o) => { await ctx.actions.file.removeFileInProject(o.path) }, { path: getPathForPlatform('cypress/e2e/dom-list.spec.js') }) cy.get('[data-cy="file-match-indicator"]') - .should('contain', '22 Matches') + .should('contain', '22 matches') }) it('handles removing the last file', () => { @@ -387,7 +387,7 @@ e2e: { }) cy.get('[data-cy="file-match-indicator"]') - .should('contain', '1 Match') + .should('contain', '1 match') cy.withCtx(async (ctx, o) => { await ctx.actions.file.removeFileInProject(o.path) @@ -404,7 +404,7 @@ e2e: { cy.get('[data-cy="spec-pattern"]').contains('cypress/e2e/**/*.spec.{js,ts}') cy.get('[data-cy="file-match-indicator"]') - .should('contain', '23 Matches') + .should('contain', '23 matches') cy.withCtx(async (ctx) => { await ctx.actions.file.writeFileInProject('cypress.config.js', @@ -428,7 +428,7 @@ e2e: { }) cy.get('[data-cy="file-match-indicator"]', { timeout: 7500 }) - .should('contain', '2 Matches') + .should('contain', '2 matches') }) }) }) diff --git a/packages/app/cypress/e2e/support/execute-spec.ts b/packages/app/cypress/e2e/support/execute-spec.ts index 70cafc11a7a8..2067bc030b57 100644 --- a/packages/app/cypress/e2e/support/execute-spec.ts +++ b/packages/app/cypress/e2e/support/execute-spec.ts @@ -18,7 +18,7 @@ declare global { * 3. Waits (with a timeout of 30s) for the Rerun all tests button to be present. This ensures all tests have completed * */ - waitForSpecToFinish(expectedResults?: ExpectedResults): void + waitForSpecToFinish(expectedResults?: ExpectedResults, timeout?: number): void } } } @@ -26,16 +26,16 @@ declare global { // Here we export the function with no intention to import it // This only tells the typescript type checker that this definitely is a module // This way, we are allowed to use the global namespace declaration -export const waitForSpecToFinish = (expectedResults) => { +export const waitForSpecToFinish = (expectedResults, timeout?: number) => { // First ensure the test is loaded cy.get('.passed > .num').should('contain', '--') cy.get('.failed > .num').should('contain', '--') // Then ensure the tests are running - cy.contains('Your tests are loading...', { timeout: 20000 }).should('not.exist') + cy.contains('Your tests are loading...', { timeout: timeout || 20000 }).should('not.exist') // Then ensure the tests have finished - cy.get('[aria-label="Rerun all tests"]', { timeout: 30000 }) + cy.get('[aria-label="Rerun all tests"]', { timeout: timeout || 30000 }) if (expectedResults) { shouldHaveTestResults(expectedResults) diff --git a/packages/app/cypress/e2e/top-nav.cy.ts b/packages/app/cypress/e2e/top-nav.cy.ts index d3a05f6515ab..330e5f0796b1 100644 --- a/packages/app/cypress/e2e/top-nav.cy.ts +++ b/packages/app/cypress/e2e/top-nav.cy.ts @@ -211,7 +211,7 @@ describe('App Top Nav Workflows', () => { cy.findByRole('dialog', { name: 'Upgrade to Cypress 10.1.0' }).as('upgradeModal').within(() => { cy.contains('You are currently running Version 10.0.0 of Cypress').should('be.visible') - cy.contains('npm install -D cypress@10.1.0').should('be.visible') + cy.findByDisplayValue('npm install -D cypress@10.1.0').should('be.visible') cy.findByRole('button', { name: 'Close' }).click() }) @@ -261,7 +261,7 @@ describe('App Top Nav Workflows', () => { it('shows popover with additional doc links', () => { cy.get('@docsButton').click().should('have.attr', 'aria-expanded', 'true') - cy.findByRole('heading', { name: 'Getting Started', level: 2 }) + cy.findByRole('heading', { name: 'Getting started', level: 2 }) cy.findByRole('heading', { name: 'References', level: 2 }) cy.findByRole('heading', { name: 'Run in CI/CD', level: 2 }) @@ -275,11 +275,11 @@ describe('App Top Nav Workflows', () => { href: 'https://on.cypress.io/testing-your-app?utm_medium=Docs+Menu&utm_content=Testing+Your+App&utm_source=Binary%3A+App', }, { - name: 'Organizing Tests', + name: 'Organizing tests', href: 'https://on.cypress.io/writing-and-organizing-tests?utm_medium=Docs+Menu&utm_content=Organizing+Tests&utm_source=Binary%3A+App', }, { - name: 'Best Practices', + name: 'Best practices', href: 'https://on.cypress.io/best-practices?utm_medium=Docs+Menu&utm_content=Best+Practices&utm_source=Binary%3A+App', }, { @@ -331,7 +331,7 @@ describe('App Top Nav Workflows', () => { cy.loginUser() cy.visitApp() - cy.findByTestId('app-header-bar').findByRole('button', { name: 'Profile and Log Out', expanded: false }).as('logInButton') + cy.findByTestId('app-header-bar').findByRole('button', { name: 'Profile and logout', expanded: false }).as('logInButton') }) it('shows user in top nav when logged in', () => { @@ -357,9 +357,9 @@ describe('App Top Nav Workflows', () => { }) }) - cy.findByRole('button', { name: 'Log Out' }).click() + cy.findByRole('button', { name: 'Log out' }).click() - cy.findByTestId('app-header-bar').findByText('Log In').should('be.visible') + cy.findByTestId('app-header-bar').findByText('Log in').should('be.visible') }) it('logouts user if cloud request returns unauthorized', () => { @@ -388,7 +388,7 @@ describe('App Top Nav Workflows', () => { cy.findByTestId('app-header-bar').within(() => { cy.findByTestId('user-avatar-title').should('not.exist') - cy.findByRole('button', { name: 'Log In' }).click() + cy.findByRole('button', { name: 'Log in' }).click() }) }) }) @@ -426,18 +426,18 @@ describe('App Top Nav Workflows', () => { function logIn ({ expectedNextStepText, displayName }) { cy.findByTestId('app-header-bar').within(() => { cy.findByTestId('user-avatar-title').should('not.exist') - cy.findByRole('button', { name: 'Log In' }).click() + cy.findByRole('button', { name: 'Log in' }).click() }) cy.findByRole('dialog', { name: 'Log in to Cypress' }).as('logInModal').within(() => { - cy.findByRole('button', { name: 'Log In' }).click() + cy.findByRole('button', { name: 'Log in' }).click() - // The Log In button transitions through a few states as the browser launch lifecycle completes - cy.findByRole('button', { name: 'Opening Browser' }).should('be.visible').and('be.disabled') + // The Log in button transitions through a few states as the browser launch lifecycle completes + cy.findByRole('button', { name: 'Opening browser' }).should('be.visible').and('be.disabled') cy.findByRole('button', { name: 'Waiting for you to log in' }).should('be.visible').and('be.disabled') }) - cy.findByRole('dialog', { name: 'Login Successful' }).within(() => { + cy.findByRole('dialog', { name: 'Login successful' }).within(() => { cy.findByText('You are now logged in as', { exact: false }).should('be.visible') cy.validateExternalLink({ name: displayName, href: 'https://on.cypress.io/dashboard/profile' }) @@ -509,11 +509,11 @@ describe('App Top Nav Workflows', () => { cy.findByTestId('app-header-bar').within(() => { cy.findByTestId('user-avatar-title').should('not.exist') - cy.findByRole('button', { name: 'Log In' }).click() + cy.findByRole('button', { name: 'Log in' }).click() }) cy.findByRole('dialog', { name: 'Log in to Cypress' }).within(() => { - cy.findByRole('button', { name: 'Log In' }).click() + cy.findByRole('button', { name: 'Log in' }).click() cy.contains('http://127.0.0.1:0000/redirect-to-auth').should('be.visible') cy.contains(loginText.titleBrowserError).should('be.visible') @@ -541,11 +541,11 @@ describe('App Top Nav Workflows', () => { cy.findByTestId('app-header-bar').within(() => { cy.findByTestId('user-avatar-title').should('not.exist') - cy.findByRole('button', { name: 'Log In' }).click() + cy.findByRole('button', { name: 'Log in' }).click() }) cy.findByRole('dialog', { name: 'Log in to Cypress' }).within(() => { - cy.findByRole('button', { name: 'Log In' }).click() + cy.findByRole('button', { name: 'Log in' }).click() cy.contains(loginText.titleFailed).should('be.visible') cy.contains(loginText.bodyError).should('be.visible') @@ -591,11 +591,11 @@ describe('App Top Nav Workflows', () => { cy.findByTestId('app-header-bar').within(() => { cy.findByTestId('user-avatar-title').should('not.exist') - cy.findByRole('button', { name: 'Log In' }).as('loginButton').click() + cy.findByRole('button', { name: 'Log in' }).as('loginButton').click() }) cy.findByRole('dialog', { name: 'Log in to Cypress' }).within(() => { - cy.findByRole('button', { name: 'Log In' }).click() + cy.findByRole('button', { name: 'Log in' }).click() cy.contains(loginText.titleFailed).should('be.visible') cy.contains(loginText.bodyError).should('be.visible') @@ -628,11 +628,11 @@ describe('App Top Nav Workflows', () => { cy.findByTestId('app-header-bar').within(() => { cy.findByTestId('user-avatar-title').should('not.exist') - cy.findByRole('button', { name: 'Log In' }).as('loginButton').click() + cy.findByRole('button', { name: 'Log in' }).as('loginButton').click() }) cy.findByRole('dialog', { name: 'Log in to Cypress' }).within(() => { - cy.findByRole('button', { name: 'Log In' }).click() + cy.findByRole('button', { name: 'Log in' }).click() cy.contains(loginText.titleFailed).should('be.visible') cy.contains(loginText.bodyError).should('be.visible') cy.contains('An unexpected error occurred').should('be.visible') diff --git a/packages/app/src/components/FileMatch.cy.tsx b/packages/app/src/components/FileMatch.cy.tsx index 8ec23e763b05..fc9cd872d48e 100644 --- a/packages/app/src/components/FileMatch.cy.tsx +++ b/packages/app/src/components/FileMatch.cy.tsx @@ -158,27 +158,27 @@ describe('', { viewportWidth: 600, viewportHeight: 300 }, () => { const matchesData: Record = { all: [ { matches: { found: 10, total } }, - '10 Matches', + '10 matches', ], 'ignores numerator when file pattern isn\'t searched': [ { matches: { found: 9, total } }, - '10 Matches', + '10 matches', ], 'shows numerator when file pattern is searched': [ { matches: { found: 9, total }, pattern: 'A Pattern', extensionPattern: '*.tsx' }, - '9 of 10 Matches', + '9 of 10 matches', ], one: [ { matches: { found: 1, total }, pattern: 'A Pattern', extensionPattern: '*.tsx' }, - '1 of 10 Matches', + '1 of 10 matches', ], 'one without a pattern': [ { matches: { found: 1, total } }, - '1 Match', + '1 match', ], 'no matches': [ { matches: { found: 0, total: 0 } }, - 'No Matches', + 'No matches', ], } diff --git a/packages/app/src/components/SpecPatterns.cy.tsx b/packages/app/src/components/SpecPatterns.cy.tsx index c7a4e0b526e0..399ad11db717 100644 --- a/packages/app/src/components/SpecPatterns.cy.tsx +++ b/packages/app/src/components/SpecPatterns.cy.tsx @@ -8,7 +8,7 @@ describe('', () => { }) cy.get('[data-cy="spec-pattern"]').contains('cypress/e2e/**/*.cy.{js,jsx,ts,tsx}') - cy.get('[data-cy="file-match-indicator"]').contains('50 Matches') + cy.get('[data-cy="file-match-indicator"]').contains('50 matches') cy.percySnapshot() }) @@ -27,7 +27,7 @@ describe('', () => { }) cy.get('[data-cy="spec-pattern"]').contains('**/*.cy.{js,jsx,ts,tsx}') - cy.get('[data-cy="file-match-indicator"]').contains('50 Matches') + cy.get('[data-cy="file-match-indicator"]').contains('50 matches') }) it('renders component spec pattern should not show matches verbiage', () => { @@ -47,7 +47,7 @@ describe('', () => { cy.get('[data-cy="file-match-indicator"]').should('contain', 'specPattern') }) - it('displays `No Matches` when specs are empty', () => { + it('displays `No matches` when specs are empty', () => { cy.mountFragment(SpecPatternsFragmentDoc, { onResult: (res) => { if (!res) { @@ -60,7 +60,7 @@ describe('', () => { render: (gql) =>
, }) - cy.get('[data-cy="file-match-indicator"]').contains('No Matches') + cy.get('[data-cy="file-match-indicator"]').contains('No matches') }) it('displays `1 Match` when specs has 1 element', () => { @@ -76,6 +76,6 @@ describe('', () => { render: (gql) =>
, }) - cy.get('[data-cy="file-match-indicator"]').contains('1 Match') + cy.get('[data-cy="file-match-indicator"]').contains('1 match') }) }) diff --git a/packages/app/src/runner/SnapshotControls.cy.tsx b/packages/app/src/runner/SnapshotControls.cy.tsx index 126d656ade43..86dd662a76e9 100644 --- a/packages/app/src/runner/SnapshotControls.cy.tsx +++ b/packages/app/src/runner/SnapshotControls.cy.tsx @@ -100,7 +100,7 @@ describe('SnapshotControls', { viewportHeight: 200, viewportWidth: 500 }, () => snapshotStore.setTestsRunningError() cy.get('body') - .findByText('Cannot show Snapshot while tests are running') + .findByText('Cannot show snapshot while tests are running') .should('be.visible') }) diff --git a/packages/app/src/runner/index.ts b/packages/app/src/runner/index.ts index 54b16d42e082..ace31aa4a8f3 100644 --- a/packages/app/src/runner/index.ts +++ b/packages/app/src/runner/index.ts @@ -22,7 +22,7 @@ import { getRunnerElement, empty } from './utils' import { IframeModel } from './iframe-model' import { AutIframe } from './aut-iframe' import { EventManager } from './event-manager' -import { client } from '@packages/socket/lib/browser' +import { createWebsocket as createWebsocketIo } from '@packages/socket/lib/browser' import { decodeBase64Unicode } from '@packages/frontend-shared/src/utils/base64' import type { AutomationElementId } from '@packages/types/src' import { useSnapshotStore } from './snapshot-store' @@ -31,11 +31,7 @@ import { useStudioStore } from '../store/studio-store' let _eventManager: EventManager | undefined export function createWebsocket (config: Cypress.Config) { - const ws = client({ - path: config.socketIoRoute, - // TODO(webkit): the websocket socket.io transport is busted in WebKit, need polling - transports: config.browser.family === 'webkit' ? ['polling'] : ['websocket'], - }) + const ws = createWebsocketIo({ path: config.socketIoRoute, browserFamily: config.browser.family }) ws.on('connect', () => { ws.emit('runner:connected') diff --git a/packages/app/src/runner/selector-playground/SelectorPlayground.cy.tsx b/packages/app/src/runner/selector-playground/SelectorPlayground.cy.tsx index 0770461c3eb5..571eb275fa19 100644 --- a/packages/app/src/runner/selector-playground/SelectorPlayground.cy.tsx +++ b/packages/app/src/runner/selector-playground/SelectorPlayground.cy.tsx @@ -59,7 +59,7 @@ describe('SelectorPlayground', () => { cy.spy(autIframe, 'toggleSelectorHighlight') expect(selectorPlaygroundStore.method).to.eq('get') - cy.get('[aria-label="Selector Methods"]').click() + cy.get('[aria-label="Selector methods"]').click() cy.findByRole('menuitem', { name: 'cy.contains' }).click().then(() => { expect(selectorPlaygroundStore.method).to.eq('contains') expect(autIframe.toggleSelectorHighlight).to.have.been.called @@ -74,15 +74,15 @@ describe('SelectorPlayground', () => { selectorPlaygroundStore.setNumElements(0) mountSelectorPlayground() - cy.get('[data-cy="playground-num-elements"]').contains('No Matches') + cy.get('[data-cy="playground-num-elements"]').contains('No matches') cy.then(() => selectorPlaygroundStore.setNumElements(1)) - cy.get('[data-cy="playground-num-elements"]').contains('1 Match') + cy.get('[data-cy="playground-num-elements"]').contains('1 match') cy.then(() => selectorPlaygroundStore.setNumElements(10)) - cy.get('[data-cy="playground-num-elements"]').contains('10 Matches') + cy.get('[data-cy="playground-num-elements"]').contains('10 matches') cy.percySnapshot() diff --git a/packages/app/src/runs/CloudConnectButton.cy.tsx b/packages/app/src/runs/CloudConnectButton.cy.tsx index 100c229de39d..09fee431c18c 100644 --- a/packages/app/src/runs/CloudConnectButton.cy.tsx +++ b/packages/app/src/runs/CloudConnectButton.cy.tsx @@ -75,6 +75,6 @@ describe('', () => { cy.contains('button', 'Connect your project').click() cy.get('[role="dialog"]').should('be.visible') - cy.get('[role="dialog"] h2').should('contain', 'Connect Project') + cy.get('[role="dialog"] h2').should('contain', 'Connect project') }) }) diff --git a/packages/app/src/runs/RunsEmpty.cy.tsx b/packages/app/src/runs/RunsEmpty.cy.tsx index 31074bd2aa4b..aa5e83c727a3 100644 --- a/packages/app/src/runs/RunsEmpty.cy.tsx +++ b/packages/app/src/runs/RunsEmpty.cy.tsx @@ -21,6 +21,6 @@ describe('RunsEmpty', () => { } as any cy.contains(defaultMessages.specPage.banners.record.title).should('be.visible') - cy.contains('npx cypress run --component --record --key abcd-efg-1234').should('be.visible') + cy.findByDisplayValue('npx cypress run --component --record --key abcd-efg-1234').should('be.visible') }) }) diff --git a/packages/app/src/runs/RunsEmpty.vue b/packages/app/src/runs/RunsEmpty.vue index e9cc4e94c000..0a8654187a2d 100644 --- a/packages/app/src/runs/RunsEmpty.vue +++ b/packages/app/src/runs/RunsEmpty.vue @@ -10,7 +10,7 @@

{{ t("runs.empty.description") }}

- + diff --git a/packages/app/src/runs/modals/SelectCloudProjectModal.vue b/packages/app/src/runs/modals/SelectCloudProjectModal.vue index d7dd728c00e6..64b9c382529c 100644 --- a/packages/app/src/runs/modals/SelectCloudProjectModal.vue +++ b/packages/app/src/runs/modals/SelectCloudProjectModal.vue @@ -160,6 +160,7 @@ size="lg" :prefix-icon="newProject ? CreateIcon : ConnectIcon" prefix-icon-class="icon-dark-white" + data-cy="connect-project" @click="createOrConnectProject" > {{ newProject diff --git a/packages/app/src/settings/SettingsContainer.cy.tsx b/packages/app/src/settings/SettingsContainer.cy.tsx index 76a766cef461..e29285f95dfb 100644 --- a/packages/app/src/settings/SettingsContainer.cy.tsx +++ b/packages/app/src/settings/SettingsContainer.cy.tsx @@ -15,36 +15,36 @@ describe('', { viewportHeight: 800, viewportWidth: 900 }, ( }) it('expands and collapses project settings', () => { - cy.contains('Project Settings').click() + cy.contains('Project settings').click() cy.findByText(defaultMessages.settingsPage.experiments.title).scrollIntoView().should('be.visible') cy.findByText(defaultMessages.settingsPage.specPattern.title).scrollIntoView().should('be.visible') cy.findByText(defaultMessages.settingsPage.config.title).scrollIntoView().should('be.visible') cy.percySnapshot() - cy.findByText('Project Settings').click() + cy.findByText('Project settings').click() cy.findByText(defaultMessages.settingsPage.experiments.title).should('not.exist') }) it('expands and collapses device settings', () => { - cy.contains('Device Settings').click() + cy.contains('Device settings').click() cy.findByText(defaultMessages.settingsPage.editor.title).should('be.visible') cy.findByText(defaultMessages.settingsPage.proxy.title).should('be.visible') cy.findByText(defaultMessages.settingsPage.testingPreferences.title).should('be.visible') cy.percySnapshot() - cy.findByText('Device Settings').click() + cy.findByText('Device settings').click() cy.findByText(defaultMessages.settingsPage.editor.title).should('not.exist') }) it('expands and collapses cloud settings', () => { - cy.contains('Dashboard Settings').click() + cy.contains('Dashboard settings').click() cy.findByText(defaultMessages.settingsPage.projectId.title).scrollIntoView().should('be.visible') cy.percySnapshot() - cy.findByText('Dashboard Settings').click() + cy.findByText('Dashboard settings').click() cy.findByText(defaultMessages.settingsPage.projectId.title).should('not.exist') }) diff --git a/packages/app/src/settings/device/ProxySettings.cy.tsx b/packages/app/src/settings/device/ProxySettings.cy.tsx index d050d5c5ac13..68a52ea5396c 100644 --- a/packages/app/src/settings/device/ProxySettings.cy.tsx +++ b/packages/app/src/settings/device/ProxySettings.cy.tsx @@ -15,10 +15,10 @@ describe('', { render: (gql) =>
, }) - cy.findByText('Proxy Bypass List') + cy.findByText('Proxy bypass list') .get('[data-testid=bypass-list]').should('have.text', 'proxy-bypass') - cy.findByText('Proxy Server') + cy.findByText('Proxy server') .get('[data-testid=proxy-server]').should('have.text', 'proxy-server') cy.percySnapshot() @@ -40,10 +40,10 @@ describe('', { render: (gql) =>
, }) - cy.findByText('Proxy Bypass List') + cy.findByText('Proxy bypass list') .get('[data-testid=bypass-list]').should('have.text', '-') - cy.findByText('Proxy Server') + cy.findByText('Proxy server') .get('[data-testid=proxy-server]').should('have.text', '-') }) }) diff --git a/packages/app/src/settings/project/CloudSettings.cy.tsx b/packages/app/src/settings/project/CloudSettings.cy.tsx index 8abc31705e31..e04b9a69704a 100644 --- a/packages/app/src/settings/project/CloudSettings.cy.tsx +++ b/packages/app/src/settings/project/CloudSettings.cy.tsx @@ -3,7 +3,7 @@ import { CloudSettingsFragmentDoc } from '../../generated/graphql-test' import CloudSettings from './CloudSettings.vue' describe('', () => { - it('displays the project Id and record key sections', () => { + it('displays the project Id and Record Key sections', () => { cy.mountFragment(CloudSettingsFragmentDoc, { render: (gqlVal) => { @@ -45,7 +45,7 @@ describe('', () => { cy.percySnapshot() }) - it('hides record key when not present', () => { + it('hides Record Key when not present', () => { cy.mountFragment(CloudSettingsFragmentDoc, { onResult (ctx) { if (ctx.currentProject?.cloudProject?.__typename === 'CloudProject') { diff --git a/packages/app/src/settings/project/RecordKey.cy.tsx b/packages/app/src/settings/project/RecordKey.cy.tsx index 3bc2c5313c12..d1189bd0ddf3 100644 --- a/packages/app/src/settings/project/RecordKey.cy.tsx +++ b/packages/app/src/settings/project/RecordKey.cy.tsx @@ -19,12 +19,12 @@ describe('', () => { }) }) - it('renders the record key view with the correct title', () => { - cy.findByText('Record Key') + it('renders the Record Key view with the correct title', () => { + cy.findByText('Record key') }) it(`has an input that's hidden by default`, () => { - cy.get('code').as('Record Key Input') + cy.get('code').as('Record key input') .should('be.visible') .contains('code', key).should('not.exist') .get('[aria-label="Record Key Visibility Toggle"]').as('Password Toggle') diff --git a/packages/app/src/settings/project/SpecPatterns.cy.tsx b/packages/app/src/settings/project/SpecPatterns.cy.tsx index 1144b0cd65af..09e6d3e281c7 100644 --- a/packages/app/src/settings/project/SpecPatterns.cy.tsx +++ b/packages/app/src/settings/project/SpecPatterns.cy.tsx @@ -15,7 +15,7 @@ describe('', () => { cy.contains('h2', defaultMessages.settingsPage.specPattern.title) cy.contains('code', 'specPattern') cy.contains('p', defaultMessages.settingsPage.specPattern.description.replace('{0}', 'Learn more')) - cy.get('[data-cy="file-match-indicator"]').contains('50 Matches') + cy.get('[data-cy="file-match-indicator"]').contains('50 matches') cy.get('[data-cy="spec-pattern"]').contains('cypress/e2e/**/*.cy.{js,jsx,ts,tsx}') cy.get('[data-cy="external"]').should('have.attr', 'href').and('eq', 'https://on.cypress.io/test-type-options') diff --git a/packages/app/src/specs/InlineSpecList.cy.tsx b/packages/app/src/specs/InlineSpecList.cy.tsx index 7d89ce3b4161..1d721a30db61 100644 --- a/packages/app/src/specs/InlineSpecList.cy.tsx +++ b/packages/app/src/specs/InlineSpecList.cy.tsx @@ -63,7 +63,7 @@ describe('InlineSpecList', () => { it('should open CreateSpec modal', () => { mountInlineSpecList() - const newSpecSelector = `[aria-label="New Spec"]` + const newSpecSelector = `[aria-label="New spec"]` cy.get(newSpecSelector).click() cy.contains(defaultMessages.createSpec.newSpecModalTitle).should('be.visible') diff --git a/packages/app/src/specs/InlineSpecListHeader.cy.tsx b/packages/app/src/specs/InlineSpecListHeader.cy.tsx index 46268e91476c..d4949f2ad57a 100644 --- a/packages/app/src/specs/InlineSpecListHeader.cy.tsx +++ b/packages/app/src/specs/InlineSpecListHeader.cy.tsx @@ -57,13 +57,13 @@ describe('InlineSpecListHeader', () => { it('exposes the result count correctly to assistive tech', () => { mountWithResultCount(0) - cy.contains('No Matches') + cy.contains('No matches') .should('have.class', 'sr-only') .and('have.attr', 'aria-live', 'polite') mountWithResultCount(1) - cy.contains('1 Match').should('have.class', 'sr-only') + cy.contains('1 match').should('have.class', 'sr-only') mountWithResultCount(100) - cy.contains('100 Matches').should('have.class', 'sr-only') + cy.contains('100 matches').should('have.class', 'sr-only') }) }) diff --git a/packages/app/src/specs/SpecsList.cy.tsx b/packages/app/src/specs/SpecsList.cy.tsx index 4ea7ccceb132..b3576437fdf6 100644 --- a/packages/app/src/specs/SpecsList.cy.tsx +++ b/packages/app/src/specs/SpecsList.cy.tsx @@ -215,17 +215,17 @@ describe('', { keystrokeDelay: 0 }, () => { cy.contains('button', defaultMessages.createSpec.viewSpecPatternButton) .as('resultsCount') - .should('contain.text', '0 of 50 Matches') + .should('contain.text', '0 of 50 matches') // confirm results clear correctly cy.contains('button', defaultMessages.noResults.clearSearch).click() cy.get('@resultsCount') - .should('contain.text', '50 Matches') + .should('contain.text', '50 matches') // the exact wording here can be deceptive so confirm it's not still // displaying "of", since X of 50 Matches would pass for containing "50 matches" // but would be wrong. - .should('not.contain.text', 'of 50 Matches') + .should('not.contain.text', 'of 50 matches') }) it('calls gql mutation to save updated filter', () => { diff --git a/packages/app/src/specs/SpecsListHeader.cy.tsx b/packages/app/src/specs/SpecsListHeader.cy.tsx index ce87349e66b5..478f7dedbfe8 100644 --- a/packages/app/src/specs/SpecsListHeader.cy.tsx +++ b/packages/app/src/specs/SpecsListHeader.cy.tsx @@ -92,19 +92,19 @@ describe('', { keystrokeDelay: 0 }, () => { } mountWithSpecCount(0) - cy.contains('No Matches') + cy.contains('No matches') .should('be.visible') .and('have.attr', 'aria-live', 'polite') - cy.percySnapshot('No Matches') + cy.percySnapshot('No matches') mountWithSpecCount(1) - cy.contains('1 Match').should('be.visible') + cy.contains('1 match').should('be.visible') cy.percySnapshot('Singular Match') mountWithSpecCount(100) - cy.contains('100 Matches').should('be.visible') + cy.contains('100 matches').should('be.visible') cy.percySnapshot('Plural Match') }) @@ -119,19 +119,19 @@ describe('', { keystrokeDelay: 0 }, () => { } mountWithCounts(0, 0) - cy.contains('No Matches') + cy.contains('No matches') mountWithCounts(0, 22) - cy.contains('0 of 22 Matches') + cy.contains('0 of 22 matches') mountWithCounts(0, 1) - cy.contains('0 of 1 Match').should('be.visible') + cy.contains('0 of 1 match').should('be.visible') mountWithCounts(1, 1) - cy.contains('1 of 1 Match').should('be.visible') + cy.contains('1 of 1 match').should('be.visible') mountWithCounts(5, 22) - cy.contains('5 of 22 Matches').should('be.visible') + cy.contains('5 of 22 matches').should('be.visible') cy.percySnapshot() }) diff --git a/packages/app/src/specs/banners/RecordBanner.cy.tsx b/packages/app/src/specs/banners/RecordBanner.cy.tsx index 076ed117157a..1b8510865723 100644 --- a/packages/app/src/specs/banners/RecordBanner.cy.tsx +++ b/packages/app/src/specs/banners/RecordBanner.cy.tsx @@ -24,7 +24,7 @@ describe('', () => { cy.contains(defaultMessages.specPage.banners.record.title).should('be.visible') cy.contains(defaultMessages.specPage.banners.record.content).should('be.visible') - cy.findByText('npx cypress run --component --record --key abcd-efg-1234') + cy.findByDisplayValue('npx cypress run --component --record --key abcd-efg-1234').should('be.visible') cy.percySnapshot() }) diff --git a/packages/app/src/specs/generators/FileChooser.cy.tsx b/packages/app/src/specs/generators/FileChooser.cy.tsx index 09f0c729cfd1..98f36a501b28 100644 --- a/packages/app/src/specs/generators/FileChooser.cy.tsx +++ b/packages/app/src/specs/generators/FileChooser.cy.tsx @@ -60,17 +60,17 @@ describe('', () => { describe('matches', () => { it('displays the total number of file matches', () => { cy.mount(() => ()) - .get(fileMatchIndicatorSelector).should('contain.text', `${allFiles.length } Matches`) + .get(fileMatchIndicatorSelector).should('contain.text', `${allFiles.length } matches`) }) it('handles pluralization', () => { cy.mount(() => ()) - .get(fileMatchIndicatorSelector).should('contain.text', `${1 } Match`) + .get(fileMatchIndicatorSelector).should('contain.text', `${1 } match`) }) it('handles no matches', () => { cy.mount(() => ()) - .get(fileMatchIndicatorSelector).should('contain.text', 'No Matches') + .get(fileMatchIndicatorSelector).should('contain.text', 'No matches') }) it('updates the number of files found out of the total number available', () => { @@ -86,15 +86,15 @@ describe('', () => { // Figure out how many files were actually matched and make sure // that they're out of the total files passed in cy.get(fileMatchIndicatorSelector) - .should('contain.text', `${$rows.length} of ${allFiles.length} Matches`) + .should('contain.text', `${$rows.length} of ${allFiles.length} matches`) // Get back to an empty state where all files are shown .get(filenameInputSelector).clear() - .get(fileMatchIndicatorSelector).should('contain.text', `${allFiles.length } Matches`) + .get(fileMatchIndicatorSelector).should('contain.text', `${allFiles.length } matches`) // Go to the no matches state .get(filenameInputSelector).type(nonExistentFileName, { delay: 0 }) - .get(fileMatchIndicatorSelector).should('contain.text', 'No Matches') + .get(fileMatchIndicatorSelector).should('contain.text', 'No matches') }) }) }) diff --git a/packages/config/src/options.ts b/packages/config/src/options.ts index 8173d48d92cc..94fb4383c233 100644 --- a/packages/config/src/options.ts +++ b/packages/config/src/options.ts @@ -141,6 +141,7 @@ const driverConfigOptions: Array = [ defaultValue: null, validation: validate.isStringOrArrayOfStrings, overrideLevel: 'any', + requireRestartOnChange: 'server', }, { name: 'chromeWebSecurity', defaultValue: true, diff --git a/packages/config/test/index.spec.ts b/packages/config/test/index.spec.ts index 0a6ded9fda8b..22de97ebb98e 100644 --- a/packages/config/test/index.spec.ts +++ b/packages/config/test/index.spec.ts @@ -231,4 +231,15 @@ describe('config/src/index', () => { expect(errorFn).to.have.callCount(0) }) }) + + describe('.validateNeedToRestartOnChange', () => { + it('returns the need to restart if given key has changed', () => { + const result = configUtil.validateNeedToRestartOnChange({ blockHosts: [] }, { blockHosts: ['https://example.com'] }) + + expect(result).to.eql({ + server: true, + browser: false, + }) + }) + }) }) diff --git a/packages/driver/cypress/e2e/commands/cookies.cy.js b/packages/driver/cypress/e2e/commands/cookies.cy.js index b739a8a7af8b..5b4872a65765 100644 --- a/packages/driver/cypress/e2e/commands/cookies.cy.js +++ b/packages/driver/cypress/e2e/commands/cookies.cy.js @@ -2,6 +2,25 @@ const { assertLogLength } = require('../../support/utils') const { stripIndent } = require('common-tags') const { Promise } = Cypress +describe('src/cy/commands/cookies - no stub', () => { + it('clears all cookies', () => { + cy.setCookie('foo', 'bar') + cy.getCookies().should('have.length', 1) + cy.clearCookies() + cy.getCookies().should('have.length', 0) + }) + + it('clears a single cookie', () => { + cy.setCookie('foo', 'bar') + cy.setCookie('key', 'val') + cy.getCookies().should('have.length', 2) + cy.clearCookie('foo') + cy.getCookies().should('have.length', 1).then((cookies) => { + expect(cookies[0].name).to.eq('key') + }) + }) +}) + describe('src/cy/commands/cookies', () => { beforeEach(() => { // call through normally on everything diff --git a/packages/driver/cypress/e2e/commands/sessions/sessions.cy.js b/packages/driver/cypress/e2e/commands/sessions/sessions.cy.js index c64965f21e2d..c48f706dea7c 100644 --- a/packages/driver/cypress/e2e/commands/sessions/sessions.cy.js +++ b/packages/driver/cypress/e2e/commands/sessions/sessions.cy.js @@ -24,6 +24,27 @@ const clearAllSavedSessions = () => { }) } +// In webkit, the clear page and clear cookies, etc log messages may be reversed. This isn't an issue, but we just want to test we have both messages. +const validateClearLogs = (logs, sessionGroupId) => { + let clearPageLogIndex = 0 + let clearCookiesIndex = 1 + + if (logs[1].get('name') === 'Clear page') { + clearPageLogIndex = 1 + clearCookiesIndex = 0 + } + + expect(logs[clearPageLogIndex].get()).to.contain({ + name: 'Clear page', + group: sessionGroupId, + }) + + expect(logs[clearCookiesIndex].get()).to.contain({ + displayName: 'Clear cookies, localStorage and sessionStorage', + group: sessionGroupId, + }) +} + describe('cy.session', { retries: 0 }, () => { describe('args', () => { it('accepts string as id', () => { @@ -200,15 +221,7 @@ describe('cy.session', { retries: 0 }, () => { }, }) - expect(logs[1].get()).to.contain({ - name: 'Clear page', - group: sessionGroupId, - }) - - expect(logs[2].get()).to.contain({ - displayName: 'Clear cookies, localStorage and sessionStorage', - group: sessionGroupId, - }) + validateClearLogs([logs[1], logs[2]], sessionGroupId) const createNewSessionGroup = logs[3].get() @@ -282,15 +295,7 @@ describe('cy.session', { retries: 0 }, () => { }, }) - expect(logs[1].get()).to.contain({ - name: 'Clear page', - group: sessionGroupId, - }) - - expect(logs[2].get()).to.contain({ - displayName: 'Clear cookies, localStorage and sessionStorage', - group: sessionGroupId, - }) + validateClearLogs([logs[1], logs[2]], sessionGroupId) const createNewSessionGroup = logs[3].get() @@ -344,15 +349,7 @@ describe('cy.session', { retries: 0 }, () => { }, }) - expect(logs[1].get()).to.contain({ - name: 'Clear page', - group: sessionGroupId, - }) - - expect(logs[2].get()).to.contain({ - displayName: 'Clear cookies, localStorage and sessionStorage', - group: sessionGroupId, - }) + validateClearLogs([logs[1], logs[2]], sessionGroupId) const createNewSessionGroup = logs[3].get() @@ -437,15 +434,7 @@ describe('cy.session', { retries: 0 }, () => { }, }) - expect(logs[1].get()).to.contain({ - name: 'Clear page', - group: sessionGroupId, - }) - - expect(logs[2].get()).to.contain({ - displayName: 'Clear cookies, localStorage and sessionStorage', - group: sessionGroupId, - }) + validateClearLogs([logs[1], logs[2]], sessionGroupId) const restoreSavedSessionGroup = logs[3].get() @@ -500,15 +489,7 @@ describe('cy.session', { retries: 0 }, () => { }, }) - expect(logs[1].get()).to.contain({ - name: 'Clear page', - group: sessionGroupId, - }) - - expect(logs[2].get()).to.contain({ - displayName: 'Clear cookies, localStorage and sessionStorage', - group: sessionGroupId, - }) + validateClearLogs([logs[1], logs[2]], sessionGroupId) const restoreSavedSessionGroup = logs[3].get() @@ -582,15 +563,7 @@ describe('cy.session', { retries: 0 }, () => { }, }) - expect(logs[1].get()).to.contain({ - name: 'Clear page', - group: sessionGroupId, - }) - - expect(logs[2].get()).to.contain({ - displayName: 'Clear cookies, localStorage and sessionStorage', - group: sessionGroupId, - }) + validateClearLogs([logs[1], logs[2]], sessionGroupId) const restoreSavedSessionGroup = logs[3].get() @@ -618,15 +591,7 @@ describe('cy.session', { retries: 0 }, () => { expect(logs[6].get('error').message).to.eq('Your `cy.session` **validate** callback returned false.') - expect(logs[7].get()).to.contain({ - name: 'Clear page', - group: sessionGroupId, - }) - - expect(logs[8].get()).to.contain({ - displayName: 'Clear cookies, localStorage and sessionStorage', - group: sessionGroupId, - }) + validateClearLogs([logs[7], logs[8]], sessionGroupId) const createNewSessionGroup = logs[9].get() @@ -692,15 +657,7 @@ describe('cy.session', { retries: 0 }, () => { }, }) - expect(logs[1].get()).to.contain({ - name: 'Clear page', - group: sessionGroupId, - }) - - expect(logs[2].get()).to.contain({ - displayName: 'Clear cookies, localStorage and sessionStorage', - group: sessionGroupId, - }) + validateClearLogs([logs[1], logs[2]], sessionGroupId) const restoreSavedSessionGroup = logs[3].get() @@ -728,15 +685,7 @@ describe('cy.session', { retries: 0 }, () => { expect(logs[6].get('error').message).to.eq('Your `cy.session` **validate** callback returned false.') - expect(logs[7].get()).to.contain({ - name: 'Clear page', - group: sessionGroupId, - }) - - expect(logs[8].get()).to.contain({ - displayName: 'Clear cookies, localStorage and sessionStorage', - group: sessionGroupId, - }) + validateClearLogs([logs[7], logs[8]], sessionGroupId) const createNewSessionGroup = logs[9].get() @@ -1046,7 +995,10 @@ describe('cy.session', { retries: 0 }, () => { cy.once('fail', (err) => { expect(err.message).contain('Expected to find element: `#does_not_exist`') expect(err.message).contain(errorHookMessage) - expect(err.codeFrame).exist + // TODO: Webkit does not have correct stack traces on errors currently + if (Cypress.isBrowser('!webkit')) { + expect(err.codeFrame).exist + } done() }) @@ -1064,7 +1016,11 @@ describe('cy.session', { retries: 0 }, () => { cy.once('fail', (err) => { expect(err.message).contain('validate error') expect(err.message).contain(errorHookMessage) - expect(err.codeFrame).exist + // TODO: Webkit does not have correct stack traces on errors currently + if (Cypress.isBrowser('!webkit')) { + expect(err.codeFrame).exist + } + done() }) @@ -1081,7 +1037,10 @@ describe('cy.session', { retries: 0 }, () => { cy.once('fail', (err) => { expect(err.message).contain('validate error') expect(err.message).contain(errorHookMessage) - expect(err.codeFrame).exist + // TODO: Webkit does not have correct stack traces on errors currently + if (Cypress.isBrowser('!webkit')) { + expect(err.codeFrame).exist + } done() }) @@ -1099,7 +1058,10 @@ describe('cy.session', { retries: 0 }, () => { cy.once('fail', (err) => { expect(err.message).to.contain('Your `cy.session` **validate** callback returned false.') expect(err.message).contain(errorHookMessage) - expect(err.codeFrame).exist + // TODO: Webkit does not have correct stack traces on errors currently + if (Cypress.isBrowser('!webkit')) { + expect(err.codeFrame).exist + } done() }) @@ -1117,7 +1079,11 @@ describe('cy.session', { retries: 0 }, () => { cy.once('fail', (err) => { expect(err.message).to.contain('Your `cy.session` **validate** callback resolved false.') expect(err.message).contain(errorHookMessage) - expect(err.codeFrame).exist + // TODO: Webkit does not have correct stack traces on errors currently + if (Cypress.isBrowser('!webkit')) { + expect(err.codeFrame).exist + } + done() }) diff --git a/packages/driver/cypress/e2e/e2e/origin/basic_login.cy.ts b/packages/driver/cypress/e2e/e2e/origin/basic_login.cy.ts index f70894cf2c46..458797b62eb4 100644 --- a/packages/driver/cypress/e2e/e2e/origin/basic_login.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/basic_login.cy.ts @@ -1,4 +1,4 @@ -describe('basic login', () => { +describe('basic login', { browser: '!webkit' }, () => { // Scenario, Token based auth. Visit site, redirect to IDP hosted on secondary origin, login and redirect back to site. describe('visit primary first', () => { it('logs in with idp redirect', () => { @@ -148,7 +148,7 @@ describe('basic login', () => { }) }) -describe('Multi-step Auth', () => { +describe('Multi-step Auth', { browser: '!webkit' }, () => { // TODO: cy.origin does not work in cy.origin yet. it.skip('final auth redirects back to localhost - nested', () => { cy.visit('/fixtures/auth/index.html') diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/actions.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/actions.cy.ts index ac5324b31d31..2dde6a666876 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/actions.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/actions.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin actions', () => { +context('cy.origin actions', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') }) diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/aliasing.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/aliasing.cy.ts index 2d6f77ebbc9d..4c7557279a6a 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/aliasing.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/aliasing.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin aliasing', () => { +context('cy.origin aliasing', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') }) diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/assertions.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/assertions.cy.ts index 6e12063ae998..5556787f8e79 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/assertions.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/assertions.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin assertions', () => { +context('cy.origin assertions', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="dom-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/connectors.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/connectors.cy.ts index f0646d8dd7e8..6226d5ad78a2 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/connectors.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/connectors.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin connectors', () => { +context('cy.origin connectors', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="dom-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/cookies.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/cookies.cy.ts index 4887980fdc22..6585492eb5c5 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/cookies.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/cookies.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs, assertLogLength } from '../../../../support/utils' -describe('cy.origin cookies', () => { +describe('cy.origin cookies', { browser: '!webkit' }, () => { context('client side', () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/files.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/files.cy.ts index ec90c2d88038..d708b9b9fc94 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/files.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/files.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin files', () => { +context('cy.origin files', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/local_storage.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/local_storage.cy.ts index 7debeaa90432..9b5137ea27d8 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/local_storage.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/local_storage.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin local storage', () => { +context('cy.origin local storage', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/location.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/location.cy.ts index 9072399b4139..3d6869c28980 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/location.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/location.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin location', () => { +context('cy.origin location', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/log.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/log.cy.ts index 2db1a85c41a7..93b3e8eacdff 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/log.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/log.cy.ts @@ -1,6 +1,6 @@ import { assertLogLength } from '../../../../support/utils' -context('cy.origin log', () => { +context('cy.origin log', { browser: '!webkit' }, () => { let logs: any = [] let lastTestLogId = '' diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/misc.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/misc.cy.ts index 2a452806c74b..42b406e4e3dd 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/misc.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/misc.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin misc', () => { +context('cy.origin misc', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="dom-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/navigation.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/navigation.cy.ts index 5d631cb481e0..3119226458d1 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/navigation.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/navigation.cy.ts @@ -1,7 +1,7 @@ const { stripIndent } = require('common-tags') import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin navigation', () => { +context('cy.origin navigation', { browser: '!webkit' }, () => { it('.go()', () => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/network_requests.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/network_requests.cy.ts index 7e05cfa03a90..c52a81b96597 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/network_requests.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/network_requests.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin network requests', () => { +context('cy.origin network requests', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="request-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/querying.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/querying.cy.ts index 49054466c506..0cc2dbcc6d91 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/querying.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/querying.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin querying', () => { +context('cy.origin querying', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="dom-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/querying_shadow.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/querying_shadow.cy.ts index 60077167cb1a..d6dfde203219 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/querying_shadow.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/querying_shadow.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin shadow dom', () => { +context('cy.origin shadow dom', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="shadow-dom-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/screenshot.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/screenshot.cy.ts index e39368c6bff5..d87d49429a23 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/screenshot.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/screenshot.cy.ts @@ -1,4 +1,4 @@ -context('cy.origin screenshot', () => { +context('cy.origin screenshot', { browser: '!webkit' }, () => { const { devicePixelRatio } = window context('set viewport', () => { diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/spies_stubs_clocks.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/spies_stubs_clocks.cy.ts index 3634e120004c..74f821c86127 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/spies_stubs_clocks.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/spies_stubs_clocks.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin spies, stubs, and clock', () => { +context('cy.origin spies, stubs, and clock', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/traversal.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/traversal.cy.ts index af34204be873..8ca80e6720c1 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/traversal.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/traversal.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin traversal', () => { +context('cy.origin traversal', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="dom-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/unsupported_commands.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/unsupported_commands.cy.ts index c10d24347bf8..2d87ce6735d0 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/unsupported_commands.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/unsupported_commands.cy.ts @@ -1,4 +1,4 @@ -context('cy.origin unsupported commands', () => { +context('cy.origin unsupported commands', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/viewport.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/viewport.cy.ts index 75ed312a0ee4..cd935c46adda 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/viewport.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/viewport.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin viewport', () => { +context('cy.origin viewport', { browser: '!webkit' }, () => { it('syncs the viewport from the primary to secondary', () => { // change the viewport in the primary first cy.viewport(320, 480) diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/waiting.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/waiting.cy.ts index 9e8c2572a11f..f6fbea48f06a 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/waiting.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/waiting.cy.ts @@ -22,7 +22,7 @@ const abortRequests = () => { reqQueue = [] } -context('cy.origin waiting', () => { +context('cy.origin waiting', { browser: '!webkit' }, () => { before(() => { cy.origin('http://www.foobar.com:3500', () => { let reqQueue: XMLHttpRequest[] = [] diff --git a/packages/driver/cypress/e2e/e2e/origin/commands/window.cy.ts b/packages/driver/cypress/e2e/e2e/origin/commands/window.cy.ts index 2f7a4d835c0d..47cb717ffb87 100644 --- a/packages/driver/cypress/e2e/e2e/origin/commands/window.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/commands/window.cy.ts @@ -1,6 +1,6 @@ import { findCrossOriginLogs } from '../../../../support/utils' -context('cy.origin window', () => { +context('cy.origin window', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="dom-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/config_env.cy.ts b/packages/driver/cypress/e2e/e2e/origin/config_env.cy.ts index a6df37a4b7a2..58b06e242096 100644 --- a/packages/driver/cypress/e2e/e2e/origin/config_env.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/config_env.cy.ts @@ -1,5 +1,5 @@ ['config', 'env'].forEach((fnName) => { - describe(`cy.origin- Cypress.${fnName}()`, () => { + describe(`cy.origin- Cypress.${fnName}()`, { browser: '!webkit' }, () => { const USED_KEYS = { foo: 'cy-origin-foo', bar: 'cy-origin-bar', diff --git a/packages/driver/cypress/e2e/e2e/origin/cookie_behavior.cy.ts b/packages/driver/cypress/e2e/e2e/origin/cookie_behavior.cy.ts index f5ad444fc4bb..b2dd35a0db5a 100644 --- a/packages/driver/cypress/e2e/e2e/origin/cookie_behavior.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/cookie_behavior.cy.ts @@ -1,4 +1,4 @@ -describe('Cookie Behavior with experimentalSessionAndOrigin=true', () => { +describe('Cookie Behavior with experimentalSessionAndOrigin=true', { browser: '!webkit' }, () => { const makeRequest = ( win: Cypress.AUTWindow, url: string, diff --git a/packages/driver/cypress/e2e/e2e/origin/cookie_login.cy.ts b/packages/driver/cypress/e2e/e2e/origin/cookie_login.cy.ts index b56425d24dd8..aa6fe91bc2f3 100644 --- a/packages/driver/cypress/e2e/e2e/origin/cookie_login.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/cookie_login.cy.ts @@ -1,6 +1,6 @@ import dayjs from 'dayjs' -describe('cy.origin - cookie login', () => { +describe('cy.origin - cookie login', { browser: '!webkit' }, () => { const { _ } = Cypress // ensures unique username so there's no risk of false positives from // test pollution @@ -71,7 +71,7 @@ describe('cy.origin - cookie login', () => { • displays "Welcome, " ****************************************************************************/ - describe('general behavior', () => { + describe('general behavior', { browser: '!webkit' }, () => { let username beforeEach(() => { diff --git a/packages/driver/cypress/e2e/e2e/origin/cypress_api.cy.ts b/packages/driver/cypress/e2e/e2e/origin/cypress_api.cy.ts index 2885165f439f..22f15eca9a7e 100644 --- a/packages/driver/cypress/e2e/e2e/origin/cypress_api.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/cypress_api.cy.ts @@ -1,6 +1,6 @@ const { assertLogLength } = require('../../../support/utils') -describe('cy.origin Cypress API', () => { +describe('cy.origin Cypress API', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/dependencies.cy.jsx b/packages/driver/cypress/e2e/e2e/origin/dependencies.cy.jsx index 309e4fb43ad9..872827dcfadc 100644 --- a/packages/driver/cypress/e2e/e2e/origin/dependencies.cy.jsx +++ b/packages/driver/cypress/e2e/e2e/origin/dependencies.cy.jsx @@ -1,4 +1,4 @@ -describe('cy.origin dependencies - jsx', () => { +describe('cy.origin dependencies - jsx', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/dependencies.cy.ts b/packages/driver/cypress/e2e/e2e/origin/dependencies.cy.ts index 860af3a5f930..f1ff753741c8 100644 --- a/packages/driver/cypress/e2e/e2e/origin/dependencies.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/dependencies.cy.ts @@ -1,4 +1,4 @@ -describe('cy.origin dependencies', () => { +describe('cy.origin dependencies', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/events.cy.ts b/packages/driver/cypress/e2e/e2e/origin/events.cy.ts index 4889eb7ea7ea..e0c80a28bdb8 100644 --- a/packages/driver/cypress/e2e/e2e/origin/events.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/events.cy.ts @@ -1,4 +1,4 @@ -describe('cy.origin', () => { +describe('cy.origin', { browser: '!webkit' }, () => { it('window:before:load event', () => { cy.visit('/fixtures/primary-origin.html') cy.on('window:before:load', (win: {testPrimaryOriginBeforeLoad: boolean}) => { diff --git a/packages/driver/cypress/e2e/e2e/origin/integrity.cy.ts b/packages/driver/cypress/e2e/e2e/origin/integrity.cy.ts index bb1f048eefe5..46f3802fb382 100644 --- a/packages/driver/cypress/e2e/e2e/origin/integrity.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/integrity.cy.ts @@ -4,7 +4,7 @@ import type { TemplateExecutor } from 'lodash' // NOTE: in order to run these tests, the following config flags need to be set // experimentalSessionAndOrigin=true // experimentalModifyObstructiveThirdPartyCode=true -describe('Integrity Preservation', () => { +describe('Integrity Preservation', { browser: '!webkit' }, () => { // Add common SRI hashes used when setting script/link integrity. // These are the ones supported by SRI (see https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity#using_subresource_integrity) // For our tests, we will use CryptoJS to calculate these hashes as they can regenerate the integrity without us having to do it manually every diff --git a/packages/driver/cypress/e2e/e2e/origin/logging.cy.ts b/packages/driver/cypress/e2e/e2e/origin/logging.cy.ts index 5c025f28c82e..14dc8c1a9e60 100644 --- a/packages/driver/cypress/e2e/e2e/origin/logging.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/logging.cy.ts @@ -1,4 +1,4 @@ -describe('cy.origin logging', () => { +describe('cy.origin logging', { browser: '!webkit' }, () => { const { _ } = Cypress it('groups callback commands on a passing test', () => { diff --git a/packages/driver/cypress/e2e/e2e/origin/navigation.cy.ts b/packages/driver/cypress/e2e/e2e/origin/navigation.cy.ts index 8d12f03066e3..835f253b19fb 100644 --- a/packages/driver/cypress/e2e/e2e/origin/navigation.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/navigation.cy.ts @@ -11,7 +11,7 @@ const reifyLogs = (logs) => { }) } -describe('navigation events', () => { +describe('navigation events', { browser: '!webkit' }, () => { let logs: any = [] beforeEach(() => { @@ -185,7 +185,7 @@ describe('navigation events', () => { }) // @ts-ignore / session support is needed for visiting about:blank between tests -describe('event timing', () => { +describe('event timing', { browser: '!webkit' }, () => { it('does not timeout when receiving a delaying:html event after cy.origin has started, but before the spec bridge is ready', () => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() @@ -206,7 +206,7 @@ describe('event timing', () => { }) // @ts-ignore / session support is needed for visiting about:blank between tests -describe('delayed navigation', { defaultCommandTimeout: 2000 }, () => { +describe('delayed navigation', { browser: '!webkit' }, { defaultCommandTimeout: 2000 }, () => { it('localhost -> localhost', () => { cy.visit('/fixtures/auth/delayedNavigate.html') cy.get('[data-cy="to-localhost"]').click() @@ -245,7 +245,7 @@ describe('delayed navigation', { defaultCommandTimeout: 2000 }, () => { }) // @ts-ignore / session support is needed for visiting about:blank between tests -describe('errors', () => { +describe('errors', { browser: '!webkit' }, () => { it('never calls cy.origin', { defaultCommandTimeout: 50 }, (done) => { cy.on('fail', (err) => { expect(err.message).to.include(`Timed out retrying after 50ms:`) diff --git a/packages/driver/cypress/e2e/e2e/origin/origin.cy.ts b/packages/driver/cypress/e2e/e2e/origin/origin.cy.ts index aa696056f255..9f200bd79e8a 100644 --- a/packages/driver/cypress/e2e/e2e/origin/origin.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/origin.cy.ts @@ -1,4 +1,4 @@ -describe('cy.origin', () => { +describe('cy.origin', { browser: '!webkit' }, () => { it('passes viewportWidth/Height state to the secondary origin', () => { const expectedViewport = [320, 480] @@ -224,7 +224,9 @@ describe('cy.origin', () => { describe('errors', () => { it('propagates secondary origin errors to the primary that occur within the test', (done) => { cy.on('fail', (err) => { - expect(err.message).to.include('variable is not defined') + const undefinedMessage = Cypress.isBrowser('webkit') ? 'Can\'t find variable: variable' : 'variable is not defined' + + expect(err.message).to.include(undefinedMessage) expect(err.message).to.include(`Variables must either be defined within the \`cy.origin()\` command or passed in using the args option.`) expect(err.stack).to.include(`Variables must either be defined within the \`cy.origin()\` command or passed in using the args option.`) // make sure that the secondary origin failures do NOT show up as spec failures or AUT failures diff --git a/packages/driver/cypress/e2e/e2e/origin/patches.cy.ts b/packages/driver/cypress/e2e/e2e/origin/patches.cy.ts index d87511a5fedd..d917b1fdfabe 100644 --- a/packages/driver/cypress/e2e/e2e/origin/patches.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/patches.cy.ts @@ -1,4 +1,4 @@ -describe('src/cross-origin/patches', () => { +describe('src/cross-origin/patches', { browser: '!webkit' }, () => { context('submit', () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') diff --git a/packages/driver/cypress/e2e/e2e/origin/rerun.cy.ts b/packages/driver/cypress/e2e/e2e/origin/rerun.cy.ts index 75a0e5e2bdd8..641119c8a641 100644 --- a/packages/driver/cypress/e2e/e2e/origin/rerun.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/rerun.cy.ts @@ -1,5 +1,5 @@ // @ts-ignore -describe('cy.origin - rerun', { }, () => { +describe('cy.origin - rerun', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/snapshots.cy.ts b/packages/driver/cypress/e2e/e2e/origin/snapshots.cy.ts index 957fc57b0d3d..49da844ba0f6 100644 --- a/packages/driver/cypress/e2e/e2e/origin/snapshots.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/snapshots.cy.ts @@ -1,7 +1,7 @@ // import to bind shouldWithTimeout into global cy commands import '../../../support/utils' -describe('cy.origin - snapshots', () => { +describe('cy.origin - snapshots', { browser: '!webkit' }, () => { const findLog = (logMap: Map, displayName: string, url: string) => { return Array.from(logMap.values()).find((log: any) => { const props = log.get() diff --git a/packages/driver/cypress/e2e/e2e/origin/spec_bridge.cy.ts b/packages/driver/cypress/e2e/e2e/origin/spec_bridge.cy.ts index 5c885b25bb04..2cab63f6f229 100644 --- a/packages/driver/cypress/e2e/e2e/origin/spec_bridge.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/spec_bridge.cy.ts @@ -1,4 +1,4 @@ -it('visits foobar.com and types foobar inside an input', () => { +it('visits foobar.com and types foobar inside an input', { browser: '!webkit' }, () => { cy.visit('/fixtures/primary-origin.html') cy.get('[data-cy="cross-origin-secondary-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/uncaught_errors.cy.ts b/packages/driver/cypress/e2e/e2e/origin/uncaught_errors.cy.ts index 6efefc99b559..fa5007da7b34 100644 --- a/packages/driver/cypress/e2e/e2e/origin/uncaught_errors.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/uncaught_errors.cy.ts @@ -1,4 +1,4 @@ -describe('cy.origin - uncaught errors', () => { +describe('cy.origin - uncaught errors', { browser: '!webkit' }, () => { beforeEach(() => { cy.visit('/fixtures/primary-origin.html') cy.get('a[data-cy="errors-link"]').click() diff --git a/packages/driver/cypress/e2e/e2e/origin/validation.cy.ts b/packages/driver/cypress/e2e/e2e/origin/validation.cy.ts index 58e32b1368b1..8cc7320fffa4 100644 --- a/packages/driver/cypress/e2e/e2e/origin/validation.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/validation.cy.ts @@ -1,4 +1,4 @@ -describe('cy.origin', () => { +describe('cy.origin', { browser: '!webkit' }, () => { describe('successes', () => { beforeEach(() => { // TODO: There seems to be a limit of 15 active spec bridges during a given test. diff --git a/packages/driver/cypress/e2e/e2e/origin/yield.cy.ts b/packages/driver/cypress/e2e/e2e/origin/yield.cy.ts index 953bade551bf..572d69ea94cb 100644 --- a/packages/driver/cypress/e2e/e2e/origin/yield.cy.ts +++ b/packages/driver/cypress/e2e/e2e/origin/yield.cy.ts @@ -1,6 +1,6 @@ import { assertLogLength } from '../../../support/utils' -describe('cy.origin yields', () => { +describe('cy.origin yields', { browser: '!webkit' }, () => { let logs: any = [] beforeEach(() => { diff --git a/packages/driver/cypress/e2e/webkit.cy.ts b/packages/driver/cypress/e2e/webkit.cy.ts index 36da5ab9c4d5..8a6bb4e269c1 100644 --- a/packages/driver/cypress/e2e/webkit.cy.ts +++ b/packages/driver/cypress/e2e/webkit.cy.ts @@ -9,17 +9,7 @@ describe('WebKit-specific behavior', { browser: 'webkit' }, () => { cy.origin('foo', () => {}) }) - it('cy.session() is disabled', (done) => { - cy.on('fail', (err) => { - expect(err.message).to.equal('`cy.session()` is not currently supported in experimental WebKit.') - expect(err.docsUrl).to.equal('https://on.cypress.io/webkit-experiment') - done() - }) - - cy.session('foo', () => {}) - }) - - it('cy.session() is disabled', (done) => { + it('forceNetworkError intercept option is disabled', (done) => { cy.on('fail', (err) => { expect(err.message).to.include('`forceNetworkError` was passed, but it is not currently supported in experimental WebKit.') expect(err.docsUrl).to.equal('https://on.cypress.io/intercept') diff --git a/packages/driver/src/cross-origin/events/socket.ts b/packages/driver/src/cross-origin/events/socket.ts index 52e28b54f0e7..05663ff13d0e 100644 --- a/packages/driver/src/cross-origin/events/socket.ts +++ b/packages/driver/src/cross-origin/events/socket.ts @@ -1,10 +1,9 @@ -import { client } from '@packages/socket/lib/browser' +import { createWebsocket } from '@packages/socket/lib/browser' export const handleSocketEvents = (Cypress) => { - const webSocket = client({ - path: Cypress.config('socketIoRoute'), - transports: ['websocket'], - }).connect() + const webSocket = createWebsocket({ path: Cypress.config('socketIoRoute'), browserFamily: Cypress.config('browser').family }) + + webSocket.connect() const onBackendRequest = (...args) => { webSocket.emit('backend:request', ...args) diff --git a/packages/driver/src/cy/commands/sessions/index.ts b/packages/driver/src/cy/commands/sessions/index.ts index 960948c3be75..58334583d2f9 100644 --- a/packages/driver/src/cy/commands/sessions/index.ts +++ b/packages/driver/src/cy/commands/sessions/index.ts @@ -25,10 +25,6 @@ export default function (Commands, Cypress, cy) { // @ts-ignore function throwIfNoSessionSupport () { - if (Cypress.isBrowser('webkit')) { - $errUtils.throwErrByPath('webkit.session') - } - if (!Cypress.config('experimentalSessionAndOrigin')) { $errUtils.throwErrByPath('sessions.experimentNotEnabled', { args: { diff --git a/packages/driver/src/cypress/cy.ts b/packages/driver/src/cypress/cy.ts index e8fc53e4ae33..7385b4adeeed 100644 --- a/packages/driver/src/cypress/cy.ts +++ b/packages/driver/src/cypress/cy.ts @@ -555,22 +555,6 @@ export class $Cy extends EventEmitter2 implements ITimeouts, IStability, IAssert let isRunnerAbleToCommunicateWithAUT: boolean - if (this.Cypress.isBrowser('webkit')) { - // WebKit's unhandledrejection event will sometimes not fire within the AUT - // due to a documented bug: https://bugs.webkit.org/show_bug.cgi?id=187822 - // To ensure that the event will always fire (and always report these - // unhandled rejections to the user), we patch the AUT's Error constructor - // to enqueue a no-op microtask when executed, which ensures that the unhandledrejection - // event handler will be executed if this Error is uncaught. - const originalError = autWindow.Error - - autWindow.Error = function __CyWebKitError (...args) { - autWindow.queueMicrotask(() => {}) - - return originalError.apply(this, args) - } - } - try { // Test to see if we can communicate with the AUT. autWindow.location.href @@ -585,6 +569,22 @@ export class $Cy extends EventEmitter2 implements ITimeouts, IStability, IAssert // If the runner can communicate, we should setup all events, otherwise just setup the window and fire the load event. if (isRunnerAbleToCommunicateWithAUT) { + if (this.Cypress.isBrowser('webkit')) { + // WebKit's unhandledrejection event will sometimes not fire within the AUT + // due to a documented bug: https://bugs.webkit.org/show_bug.cgi?id=187822 + // To ensure that the event will always fire (and always report these + // unhandled rejections to the user), we patch the AUT's Error constructor + // to enqueue a no-op microtask when executed, which ensures that the unhandledrejection + // event handler will be executed if this Error is uncaught. + const originalError = autWindow.Error + + autWindow.Error = function __CyWebKitError (...args) { + autWindow.queueMicrotask(() => {}) + + return originalError.apply(this, args) + } + } + setWindowDocumentProps(autWindow, this.state) // we may need to update the url now diff --git a/packages/driver/src/cypress/error_messages.ts b/packages/driver/src/cypress/error_messages.ts index 6449651af18c..2505ed396f9b 100644 --- a/packages/driver/src/cypress/error_messages.ts +++ b/packages/driver/src/cypress/error_messages.ts @@ -2413,7 +2413,6 @@ export default { webkit: { docsUrl: 'https://on.cypress.io/webkit-experiment', origin: '`cy.origin()` is not currently supported in experimental WebKit.', - session: '`cy.session()` is not currently supported in experimental WebKit.', }, window: { diff --git a/packages/driver/src/cypress/error_utils.ts b/packages/driver/src/cypress/error_utils.ts index c3d1925681bc..6fdf26aa747f 100644 --- a/packages/driver/src/cypress/error_utils.ts +++ b/packages/driver/src/cypress/error_utils.ts @@ -9,7 +9,7 @@ import $stackUtils, { StackAndCodeFrameIndex } from './stack_utils' import $utils from './utils' import type { HandlerType } from './runner' -const ERROR_PROPS = 'message type name stack parsedStack fileName lineNumber columnNumber host uncaught actual expected showDiff isPending docsUrl codeFrame'.split(' ') +const ERROR_PROPS = ['message', 'type', 'name', 'stack', 'parsedStack', 'fileName', 'lineNumber', 'columnNumber', 'host', 'uncaught', 'actual', 'expected', 'showDiff', 'isPending', 'docsUrl', 'codeFrame'] as const const ERR_PREPARED_FOR_SERIALIZATION = Symbol('ERR_PREPARED_FOR_SERIALIZATION') const crossOriginScriptRe = /^script error/i diff --git a/packages/driver/src/cypress/mocha.ts b/packages/driver/src/cypress/mocha.ts index 39527f83f7f9..7fb441dc32fb 100644 --- a/packages/driver/src/cypress/mocha.ts +++ b/packages/driver/src/cypress/mocha.ts @@ -35,13 +35,22 @@ const suiteAfterEach = Suite.prototype.afterEach delete (window as any).mocha delete (window as any).Mocha -function invokeFnWithOriginalTitle (ctx, originalTitle, mochaArgs, fn, _testConfig) { - const ret = fn.apply(ctx, mochaArgs) +type MochaArgs = [string, Function | undefined] +function createRunnable (ctx, fnType: 'Test' | 'Suite', mochaArgs: MochaArgs, runnableFn: Function, testCallback: Function | string = '', _testConfig?: Record) { + const runnable = runnableFn.apply(ctx, mochaArgs) - ret._testConfig = _testConfig - ret.originalTitle = originalTitle + // attached testConfigOverrides will execute before `runner:test:before:run` event + if (_testConfig) { + runnable._testConfig = _testConfig + } + + if (fnType === 'Test') { + // persist the original callback so we can send it to the cloud + // to prevent it from being registered as a modified test + runnable.body = testCallback.toString() + } - return ret + return runnable } function overloadMochaFnForConfig (fnName, specWindow) { @@ -66,40 +75,44 @@ function overloadMochaFnForConfig (fnName, specWindow) { const origFn = subFn ? _fn[subFn] : _fn + // fallback to empty string for stubbed runnables written like: + // - describe('concept') + // - it('does something') + let testCallback = args[1] + if (args.length > 2 && _.isObject(args[1])) { const _testConfig = _.extend({}, args[1]) as any - const mochaArgs = [args[0], args[2]] + const mochaArgs: MochaArgs = [args[0], args[2]] + const originalTitle = mochaArgs[0] + + // fallback to empty string for stubbed runnables written like: + // - describe('concept') + // - it('does something') + testCallback = mochaArgs[1] const configMatchesBrowser = _testConfig.browser == null || Cypress.isBrowser(_testConfig.browser, `${fnType} config value \`{ browser }\``) if (!configMatchesBrowser) { - // TODO: this would mess up the dashboard since it would be registered as a new test - const originalTitle = mochaArgs[0] - mochaArgs[0] = `${originalTitle} (skipped due to browser)` - // TODO: weird edge case where you have an .only but also skipped the test due to the browser + // skip test at run-time when test is marked with .only but should also be skipped the test due to the browser if (subFn === 'only') { mochaArgs[1] = function () { this.skip() } - return invokeFnWithOriginalTitle(this, originalTitle, mochaArgs, origFn, _testConfig) + return createRunnable(this, fnType, mochaArgs, origFn, testCallback, _testConfig) } - return invokeFnWithOriginalTitle(this, originalTitle, mochaArgs, _fn['skip'], _testConfig) + // skip test with .skip func to ignore the test case and not run it + return createRunnable(this, fnType, mochaArgs, _fn['skip'], testCallback, _testConfig) } - const ret = origFn.apply(this, mochaArgs) - - // attached testConfigOverrides will execute before `runner:test:before:run` event - ret._testConfig = _testConfig - - return ret + return createRunnable(this, fnType, mochaArgs, origFn, testCallback, _testConfig) } - return origFn.apply(this, args) + return createRunnable(this, fnType, args as MochaArgs, origFn, testCallback) } } diff --git a/packages/driver/src/cypress/runner.ts b/packages/driver/src/cypress/runner.ts index e0e0bbb2dd5a..cb545a8f3b1b 100644 --- a/packages/driver/src/cypress/runner.ts +++ b/packages/driver/src/cypress/runner.ts @@ -14,15 +14,17 @@ import type { Emissions } from '@packages/types' const mochaCtxKeysRe = /^(_runnable|test)$/ const betweenQuotesRe = /\"(.+?)\"/ -const HOOKS = 'beforeAll beforeEach afterEach afterAll'.split(' ') +const HOOKS = ['beforeAll', 'beforeEach', 'afterEach', 'afterAll'] as const const TEST_BEFORE_RUN_ASYNC_EVENT = 'runner:test:before:run:async' // event fired before hooks and test execution const TEST_BEFORE_RUN_EVENT = 'runner:test:before:run' const TEST_AFTER_RUN_EVENT = 'runner:test:after:run' const TEST_AFTER_RUN_ASYNC_EVENT = 'runner:runnable:after:run:async' -const RUNNABLE_LOGS = 'routes agents commands hooks'.split(' ') -const RUNNABLE_PROPS = '_testConfig id order title _titlePath root hookName hookId err state failedFromHookId body speed type duration wallClockStartedAt wallClockDuration timings file originalTitle invocationDetails final currentRetry retries _slow'.split(' ') +const RUNNABLE_LOGS = ['routes', 'agents', 'commands', 'hooks'] as const +const RUNNABLE_PROPS = [ + '_testConfig', 'id', 'order', 'title', '_titlePath', 'root', 'hookName', 'hookId', 'err', 'state', 'failedFromHookId', 'body', 'speed', 'type', 'duration', 'wallClockStartedAt', 'wallClockDuration', 'timings', 'file', 'originalTitle', 'invocationDetails', 'final', 'currentRetry', 'retries', '_slow', +] as const const debug = debugFn('cypress:driver:runner') const debugErrors = debugFn('cypress:driver:errors') @@ -147,11 +149,14 @@ const setWallClockDuration = (test) => { // tests to an id-based object which prevents // us from recursively iterating through every // parent since we could just return the found test -const wrap = (runnable) => { +const wrap = (runnable): Record | null => { return $utils.reduceProps(runnable, RUNNABLE_PROPS) } -const wrapAll = (runnable): any => { +// Reduce runnable down to its props and collections. +// Sent to the Reporter to populate command log +// and send to the Dashboard when in record mode. +const wrapAll = (runnable): Record => { return _.extend( {}, $utils.reduceProps(runnable, RUNNABLE_PROPS), @@ -468,9 +473,8 @@ const overrideRunnerHook = (Cypress, _runner, getTestById, getTest, setTest, get const getTestResults = (tests) => { return _.map(tests, (test) => { - const obj: Record = _.pick(test, 'id', 'duration', 'state') + const obj: Record = _.pick(test, 'title', 'id', 'duration', 'state') - obj.title = test.originalTitle // TODO FIX THIS! if (!obj.state) { obj.state = 'skipped' @@ -565,11 +569,7 @@ const normalize = (runnable, tests, initialTests, getRunnableId, getHookId, getO prevAttempts = [] if (i.prevAttempts) { - prevAttempts = _.map(i.prevAttempts, (test) => { - // reduce this runnable down to its props - // and collections - return wrapAll(test) - }) + prevAttempts = _.map(i.prevAttempts, wrapAll) } _.extend(runnable, i) @@ -578,8 +578,6 @@ const normalize = (runnable, tests, initialTests, getRunnableId, getHookId, getO // merge all hooks into single array runnable.hooks = condenseHooks(runnable, getHookId) - // reduce this runnable down to its props - // and collections const wrappedRunnable = wrapAll(runnable) if (runnable.type === 'test') { diff --git a/packages/driver/src/cypress/utils.ts b/packages/driver/src/cypress/utils.ts index d9afe10461cf..38d4d186940b 100644 --- a/packages/driver/src/cypress/utils.ts +++ b/packages/driver/src/cypress/utils.ts @@ -100,7 +100,7 @@ export default { throw new Error(`The switch/case value: '${value}' did not match any cases: ${keys.join(', ')}.`) }, - reduceProps (obj, props: string[] = []) { + reduceProps (obj, props: readonly string[] = []) { if (!obj) { return null } diff --git a/packages/errors/__snapshot-html__/DASHBOARD_GRAPHQL_ERROR.html b/packages/errors/__snapshot-html__/DASHBOARD_GRAPHQL_ERROR.html index 413cee104d0c..a67930f5522b 100644 --- a/packages/errors/__snapshot-html__/DASHBOARD_GRAPHQL_ERROR.html +++ b/packages/errors/__snapshot-html__/DASHBOARD_GRAPHQL_ERROR.html @@ -34,7 +34,7 @@ -
We received an unexpected error response from the request to the Cypress dashboard:
+    
We received an unexpected error response from the request to the Cypress Dashboard:
 
 "fail whale"
 
diff --git a/packages/errors/__snapshot-html__/DASHBOARD_RECORD_KEY_NOT_VALID.html b/packages/errors/__snapshot-html__/DASHBOARD_RECORD_KEY_NOT_VALID.html
index 59ef0c222877..1583c8ae4003 100644
--- a/packages/errors/__snapshot-html__/DASHBOARD_RECORD_KEY_NOT_VALID.html
+++ b/packages/errors/__snapshot-html__/DASHBOARD_RECORD_KEY_NOT_VALID.html
@@ -38,7 +38,7 @@
 
 It may have been recently revoked by you or another user.
 
-Please log into the Dashboard to see the valid record keys.
+Please log into the Dashboard to see the valid Record Keys.
 
 https://on.cypress.io/dashboard/projects/project-id-123
 
\ No newline at end of file diff --git a/packages/errors/src/errors.ts b/packages/errors/src/errors.ts index 456915870395..096043e12a2a 100644 --- a/packages/errors/src/errors.ts +++ b/packages/errors/src/errors.ts @@ -483,7 +483,7 @@ export const AllCypressErrors = { It may have been recently revoked by you or another user. - Please log into the Dashboard to see the valid record keys. + Please log into the Dashboard to see the valid Record Keys. https://on.cypress.io/dashboard/projects/${fmt.off(projectId)}` }, @@ -1425,7 +1425,7 @@ export const AllCypressErrors = { DASHBOARD_GRAPHQL_ERROR: (err: Error) => { return errTemplate` - We received an unexpected error response from the request to the Cypress dashboard: + We received an unexpected error response from the request to the Cypress Dashboard: ${fmt.stringify(err.message)} ` diff --git a/packages/frontend-shared/src/components/TerminalPrompt.cy.tsx b/packages/frontend-shared/src/components/TerminalPrompt.cy.tsx index e68b7ed53905..f59afbd6ee60 100644 --- a/packages/frontend-shared/src/components/TerminalPrompt.cy.tsx +++ b/packages/frontend-shared/src/components/TerminalPrompt.cy.tsx @@ -23,7 +23,7 @@ describe('', () => { )) - cy.contains(command) + cy.findByDisplayValue(command).should('be.visible') cy.contains('button', defaultMessages.clipboard.copy) .should('be.visible') .percySnapshot() diff --git a/packages/frontend-shared/src/components/TerminalPrompt.vue b/packages/frontend-shared/src/components/TerminalPrompt.vue index e9ff97883a5c..4a7266d2065f 100644 --- a/packages/frontend-shared/src/components/TerminalPrompt.vue +++ b/packages/frontend-shared/src/components/TerminalPrompt.vue @@ -1,11 +1,17 @@