diff --git a/.circleci/cache-version.txt b/.circleci/cache-version.txt index ed09e243fb..f82a827eb2 100644 --- a/.circleci/cache-version.txt +++ b/.circleci/cache-version.txt @@ -1,3 +1,3 @@ # Bump this version to force CI to re-create the cache from scratch. -12-04-24 +12-11-24 diff --git a/.gitignore b/.gitignore index f3b35c67c6..1109337211 100644 --- a/.gitignore +++ b/.gitignore @@ -280,7 +280,9 @@ typings/ # Output of 'npm pack' *.tgz -# Yarn Integrity file +# Yarn files that shouldn't be checked in +.yarnrc +.yarn/ .yarn-integrity # dotenv environment variables file diff --git a/browser-versions.json b/browser-versions.json index d402b7236b..8379484110 100644 --- a/browser-versions.json +++ b/browser-versions.json @@ -1,5 +1,5 @@ { - "chrome:beta": "132.0.6834.32", - "chrome:stable": "131.0.6778.108", + "chrome:beta": "132.0.6834.57", + "chrome:stable": "131.0.6778.204", "chrome:minimum": "64.0.3282.0" } diff --git a/cli/CHANGELOG.md b/cli/CHANGELOG.md index ff960db5c9..4fc58f782e 100644 --- a/cli/CHANGELOG.md +++ b/cli/CHANGELOG.md @@ -66,15 +66,19 @@ in this [GitHub issue](https://github.com/cypress-io/cypress/issues/30447). Addr - Updated `react` from `17.0.2` to `18.3.1` and `react-dom` from `17.0.2` to `18.3.1`. Addresses [#30511](https://github.com/cypress-io/cypress/issues/30511). - Upgraded [`@vue/test-utils`](https://www.npmjs.com/package/@vue/test-utils) from `2.3.2` to `2.4.6`. Addresses [#26628](https://github.com/cypress-io/cypress/issues/26628). -## 13.16.2 +## 13.17.0 -_Released 12/17/2024 (PENDING)_ +_Released 12/17/2024_ + +**Features:** + +- Added official support for the [Google Chrome for Testing](https://github.com/GoogleChromeLabs/chrome-for-testing) browser. Assuming the browser is in a location where it can be [auto-detected](https://on.cypress.io/troubleshooting-launching-browsers), it can be launched by providing the `--browser chrome-for-testing` option. If it can't be auto-detected, the path to the browser can also be provided. Previously [customizing the available browsers](https://on.cypress.io/customize-browsers) was required. Addresses [#28123](https://github.com/cypress-io/cypress/issues/28123) and [#28554](https://github.com/cypress-io/cypress/issues/28554). **Bugfixes:** - Fixed an issue where targets may hang if `Network.enable` is not implemented for the target. Addresses [#29876](https://github.com/cypress-io/cypress/issues/29876). - Updated Firefox `userChrome.css` to correctly hide the toolbox during headless mode. Addresses [#30721](https://github.com/cypress-io/cypress/issues/30721). -- Fixed an issue loading the `cypress.config.ts` file with Node.js version `22.12.0`. Addresses [#30715](https://github.com/cypress-io/cypress/issues/30715). +- Fixed an issue loading the `cypress.config.ts` file with Node.js version `22.12.0` if it is loaded as an ESM. Addresses [#30715](https://github.com/cypress-io/cypress/issues/30715). **Misc:** diff --git a/package.json b/package.json index df67ab1263..e2bc39dd78 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "cypress", - "version": "13.16.1", + "version": "13.17.0", "description": "Cypress is a next generation front end testing tool built for the modern web", "private": true, "scripts": { @@ -213,7 +213,7 @@ }, "engines": { "node": ">=20.18.1", - "yarn": ">=1.22.17" + "yarn": ">=1.22.22" }, "productName": "Cypress", "license": "MIT", diff --git a/packages/app/cypress/e2e/top-nav.cy.ts b/packages/app/cypress/e2e/top-nav.cy.ts index 417642390f..52ec9e8d7b 100644 --- a/packages/app/cypress/e2e/top-nav.cy.ts +++ b/packages/app/cypress/e2e/top-nav.cy.ts @@ -44,7 +44,7 @@ describe('App Top Nav Workflows', () => { .should('have.attr', 'src') .and('contain', 'firefox') - cy.findByTestId('top-nav-active-browser').should('contain', 'Firefox 5') + cy.findByTestId('top-nav-active-browser').should('contain', 'Firefox 6') }) }) @@ -82,19 +82,19 @@ describe('App Top Nav Workflows', () => { cy.get('@browserItems').eq(1) .should('contain', 'Edge') - .and('contain', 'Version 8') + .and('contain', 'Version 9') .findByTestId('top-nav-browser-list-selected-item') .should('not.exist') cy.get('@browserItems').eq(2) .should('contain', 'Electron') - .and('contain', 'Version 12') + .and('contain', 'Version 13') .findByTestId('top-nav-browser-list-selected-item') .should('not.exist') cy.get('@browserItems').eq(3) .should('contain', 'Firefox') - .and('contain', 'Version 5') + .and('contain', 'Version 6') .findByTestId('top-nav-browser-list-selected-item') .should('not.exist') }) diff --git a/packages/app/src/debug/LayeredBrowserIcons.cy.tsx b/packages/app/src/debug/LayeredBrowserIcons.cy.tsx index 2de78fafab..410812b465 100644 --- a/packages/app/src/debug/LayeredBrowserIcons.cy.tsx +++ b/packages/app/src/debug/LayeredBrowserIcons.cy.tsx @@ -2,7 +2,7 @@ import LayeredBrowserIcons from './LayeredBrowserIcons.vue' import type { BrowserType } from './LayeredBrowserIcons.vue' describe('', () => { - const browsers: BrowserType[] = ['CHROME', 'CHROME-CANARY', 'CHROME BETA', 'FIREFOX', 'WEBKIT', 'EDGE', 'ELECTRON'] + const browsers: BrowserType[] = ['CHROME', 'CHROME BETA', 'CANARY', 'CHROME CANARY', 'CHROME FOR TESTING', 'CUSTOM CHROME FOR TESTING', 'CHROMIUM', 'CUSTOM CHROMIUM', 'EDGE', 'EDGE BETA', 'EDGE CANARY', 'EDGE DEV', 'ELECTRON', 'FIREFOX', 'FIREFOX DEVELOPER EDITION', 'FIREFOX NIGHTLY', 'WEBKIT'] it('mounts correctly for single browser', () => { browsers.forEach((ele) => { @@ -21,11 +21,11 @@ describe('', () => {
- + - + - +
)) diff --git a/packages/app/src/debug/LayeredBrowserIcons.vue b/packages/app/src/debug/LayeredBrowserIcons.vue index 07bb58c767..4cb4032cd3 100644 --- a/packages/app/src/debug/LayeredBrowserIcons.vue +++ b/packages/app/src/debug/LayeredBrowserIcons.vue @@ -20,20 +20,19 @@ diff --git a/packages/app/tsconfig.json b/packages/app/tsconfig.json index a96c821699..347deb1bb0 100644 --- a/packages/app/tsconfig.json +++ b/packages/app/tsconfig.json @@ -13,7 +13,6 @@ ], "compilerOptions": { "noImplicitThis": true, - "useDefineForClassFields": true, "paths": { "@cy/i18n": ["../frontend-shared/src/locales/i18n"], "@cy/components/*": ["../frontend-shared/src/components/*"], @@ -21,7 +20,6 @@ "@cy/store/*": ["../frontend-shared/src/store/*"], "@packages/*": ["../*"] }, - "allowJs": true, "types": [ "cypress", "cypress-real-events", diff --git a/packages/config/tsconfig.json b/packages/config/tsconfig.json index 06872625a5..cf4b494620 100644 --- a/packages/config/tsconfig.json +++ b/packages/config/tsconfig.json @@ -7,19 +7,9 @@ "test" ], "compilerOptions": { - "strict": true, "allowJs": false, "rootDir": "src", "noImplicitAny": true, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", "types": ["node"], "typeRoots": [ "../../node_modules/@types" diff --git a/packages/data-context/tsconfig.json b/packages/data-context/tsconfig.json index 69d4331d90..587382a749 100644 --- a/packages/data-context/tsconfig.json +++ b/packages/data-context/tsconfig.json @@ -9,19 +9,8 @@ ], "compilerOptions": { "lib": ["esnext"], - "strict": true, "allowJs": false, "noImplicitAny": true, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUnusedLocals": false, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", "types": ["cypress"], } } \ No newline at end of file diff --git a/packages/driver/tsconfig.json b/packages/driver/tsconfig.json index b22d122add..33203e3700 100644 --- a/packages/driver/tsconfig.json +++ b/packages/driver/tsconfig.json @@ -3,23 +3,15 @@ "compilerOptions": { "target": "ES2016", "lib": ["ES2021", "DOM", "DOM.Iterable"], - "module": "commonjs", "allowJs": true, - "noImplicitAny": false, "noImplicitThis": false, "strictFunctionTypes": true, "preserveWatchOutput": true, "sourceMap": true, - "importHelpers": true, "strictNullChecks": true, - "strict": true, "forceConsistentCasingInFileNames": true, - "skipLibCheck": true, "noEmit": true, - "noImplicitReturns": true, - "allowSyntheticDefaultImports": true, "outDir": "dist", - "esModuleInterop": true, "noErrorTruncation": true, "types": [] }, diff --git a/packages/errors/__snapshot-html__/BROWSER_NOT_FOUND_BY_NAME - canary.html b/packages/errors/__snapshot-html__/BROWSER_NOT_FOUND_BY_NAME - canary.html index 95f021d547..f3176b9f8e 100644 --- a/packages/errors/__snapshot-html__/BROWSER_NOT_FOUND_BY_NAME - canary.html +++ b/packages/errors/__snapshot-html__/BROWSER_NOT_FOUND_BY_NAME - canary.html @@ -42,7 +42,7 @@ - electron - chrome - chromium - - chrome:canary + - chrome-for-testing - edge - firefox @@ -50,18 +50,19 @@ Available browsers found on your system are: - chrome - - chromium - chrome:beta - chrome:canary + - chrome-for-testing + - chromium - firefox - firefox:dev - firefox:nightly - edge - - edge:canary - edge:beta + - edge:canary - edge:dev Note: In Cypress version 4.0.0, Canary must be launched as chrome:canary, not canary. -See https://on.cypress.io/migration-guide for more information on breaking changes in 4.0.0. +See https://on.cypress.io/migration-guide for more information on breaking changes in 4.0.0. \ No newline at end of file diff --git a/packages/errors/__snapshot-html__/BROWSER_NOT_FOUND_BY_NAME.html b/packages/errors/__snapshot-html__/BROWSER_NOT_FOUND_BY_NAME.html index d29ace7a0d..2ee1cd1ce6 100644 --- a/packages/errors/__snapshot-html__/BROWSER_NOT_FOUND_BY_NAME.html +++ b/packages/errors/__snapshot-html__/BROWSER_NOT_FOUND_BY_NAME.html @@ -42,7 +42,7 @@ - electron - chrome - chromium - - chrome:canary + - chrome-for-testing - edge - firefox @@ -50,14 +50,15 @@ Available browsers found on your system are: - chrome - - chromium - chrome:beta - chrome:canary + - chrome-for-testing + - chromium - firefox - firefox:dev - firefox:nightly - edge - - edge:canary - edge:beta - - edge:dev + - edge:canary + - edge:dev \ No newline at end of file diff --git a/packages/errors/src/errors.ts b/packages/errors/src/errors.ts index 8d1dcef3aa..7c54f6d0ba 100644 --- a/packages/errors/src/errors.ts +++ b/packages/errors/src/errors.ts @@ -120,7 +120,7 @@ export const AllCypressErrors = { Browser: ${fmt.highlight(browser)} was not found on your system or is not supported by Cypress. Cypress supports the following browsers: - ${fmt.listItems(['electron', 'chrome', 'chromium', 'chrome:canary', 'edge', 'firefox'])} + ${fmt.listItems(['electron', 'chrome', 'chromium', 'chrome-for-testing', 'edge', 'firefox'])} You can also use a custom browser: https://on.cypress.io/customize-browsers diff --git a/packages/errors/tsconfig.json b/packages/errors/tsconfig.json index e4d65fa866..dfb951b17c 100644 --- a/packages/errors/tsconfig.json +++ b/packages/errors/tsconfig.json @@ -4,18 +4,8 @@ "src", ], "compilerOptions": { - "strict": true, "allowJs": false, "noImplicitAny": true, - "resolveJsonModule": true, - "experimentalDecorators": true, "noImplicitReturns": false, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", } } \ No newline at end of file diff --git a/packages/extension/tsconfig.json b/packages/extension/tsconfig.json index 2553bd5cab..aa78286619 100644 --- a/packages/extension/tsconfig.json +++ b/packages/extension/tsconfig.json @@ -1,12 +1,7 @@ { + "extends": "../ts/tsconfig.json", "compilerOptions": { "target": "es2015", - "module": "commonjs", - "allowJs": true, - "allowSyntheticDefaultImports": true, - "esModuleInterop": true, - "noImplicitAny": false, - "importHelpers": true, "strict": false } } diff --git a/packages/frontend-shared/src/assets/browserLogos.ts b/packages/frontend-shared/src/assets/browserLogos.ts index fb572f9c62..fb1317acd3 100644 --- a/packages/frontend-shared/src/assets/browserLogos.ts +++ b/packages/frontend-shared/src/assets/browserLogos.ts @@ -4,6 +4,7 @@ import edgeIcon from 'browser-logos/src/edge/edge.svg?url' import electronIcon from 'browser-logos/src/electron/electron.svg?url' import canaryIcon from 'browser-logos/src/chrome-canary/chrome-canary.svg?url' import chromeBetaIcon from 'browser-logos/src/chrome-beta/chrome-beta.svg?url' +import chromeTestIcon from '@packages/frontend-shared/src/assets/logos/browser-chrome-for-testing_x16.svg?url' import chromiumIcon from 'browser-logos/src/chromium/chromium.svg?url' import edgeBetaIcon from 'browser-logos/src/edge-beta/edge-beta.png' import edgeCanaryIcon from 'browser-logos/src/edge-canary/edge-canary.png' @@ -16,11 +17,12 @@ import genericBrowserLogo from '@packages/frontend-shared/src/assets/logos/gener export const allBrowsersIcons = { 'Electron': electronIcon, 'Chrome': chromeIcon, + 'Chrome Beta': chromeBetaIcon, + 'Chrome Canary': canaryIcon, + 'Chrome for Testing': chromeTestIcon, 'Firefox': firefoxIcon, 'Edge': edgeIcon, 'Chromium': chromiumIcon, - 'Canary': canaryIcon, - 'Chrome Beta': chromeBetaIcon, 'Firefox Nightly': firefoxNightlyIcon, 'Firefox Developer Edition': firefoxDeveloperEditionIcon, 'Edge Canary': edgeCanaryIcon, diff --git a/packages/frontend-shared/src/assets/logos/browser-chrome-for-testing_x16.svg b/packages/frontend-shared/src/assets/logos/browser-chrome-for-testing_x16.svg new file mode 100644 index 0000000000..0426ce0ae6 --- /dev/null +++ b/packages/frontend-shared/src/assets/logos/browser-chrome-for-testing_x16.svg @@ -0,0 +1,33 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/packages/frontend-shared/tsconfig.json b/packages/frontend-shared/tsconfig.json index 29b65c4403..4c289529ab 100644 --- a/packages/frontend-shared/tsconfig.json +++ b/packages/frontend-shared/tsconfig.json @@ -1,55 +1,12 @@ { + "extends": "../ts/tsconfig.json", "compilerOptions": { - /* Basic Options */ - "target": "ES2018", "module": "esnext", "lib": ["dom", "ESNext"], - /* - * Allow javascript files to be compiled. - * Override this in modules that need JS - */ - "noEmit": true, "jsx": "preserve", "preserveWatchOutput": true, - // "checkJs": true, /* Report errors in .js files. */ - // "jsx": "preserve", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */ - /* Generates corresponding '.d.ts' file. */ - // "declaration": true, - // "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */ - /* Generates corresponding '.map' file. */ - "sourceMap": true, - /* Import emit helpers from 'tslib'. */ - "importHelpers": true, - "strictNullChecks": true, - // "downlevelIteration": true, /* Provide full support for iterables in 'for-of', spread, and destructuring when targeting 'ES5' or 'ES3'. */ - // "isolatedModules": true, /* Transpile each file as a separate module (similar to 'ts.transpileModule'). */ - /* Strict Type-Checking Options */ - // "traceResolution": true, - "strict": true, - "noImplicitAny": false, "noImplicitThis": false, - "forceConsistentCasingInFileNames": true, - /** - * Skip type checking of all declaration files (*.d.ts). - * TODO: Look into changing this in the future - */ - /* Additional Checks */ - "skipLibCheck": true, - /* Report errors on unused locals. */ - // "noEmit": true, - "noUnusedLocals": false, - // "noUnusedParameters": true, /* Report errors on unused parameters. */ - /* Report error when not all code paths in function return a value. */ - "noImplicitReturns": true, - // "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */ - /* Module Resolution Options */ - "moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */ - // "baseUrl": "./", /* Base directory to resolve non-absolute module names. */ - // "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */ - // "rootDirs": ["../driver/src"], /* List of root folders whose combined content represents the structure of the project at runtime. */ - // "typeRoots": [] /* List of folders to include type definitions from. */ - - /* Type declaration files to be included in compilation. */ + "noErrorTruncation": true, "paths": { "@cy/i18n": ["../frontend-shared/src/locales/i18n"], "@cy/components/*": ["../frontend-shared/src/components/*"] @@ -63,17 +20,5 @@ "cypress-real-events", "cypress" ], - "allowSyntheticDefaultImports": true, - "esModuleInterop": true, - "noErrorTruncation": true, - "experimentalDecorators": true, - "resolveJsonModule": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", - "useUnknownInCatchVariables": false } } diff --git a/packages/graphql/src/utils/nexusTypegenUtils.ts b/packages/graphql/src/utils/nexusTypegenUtils.ts index bd8793b09e..f209bc45af 100644 --- a/packages/graphql/src/utils/nexusTypegenUtils.ts +++ b/packages/graphql/src/utils/nexusTypegenUtils.ts @@ -92,7 +92,6 @@ const nexusTypegenDebounced = (cfg: NexusTypegenCfg) => { debounced[cfg.filePath] = debounced[cfg.filePath] ?? _.debounce(nexusTypegen, 500) - // @ts-expect-error debounced[cfg.filePath](cfg) } diff --git a/packages/graphql/tsconfig.json b/packages/graphql/tsconfig.json index 1b1ae93cc4..d7e45065be 100644 --- a/packages/graphql/tsconfig.json +++ b/packages/graphql/tsconfig.json @@ -10,19 +10,8 @@ ], "compilerOptions": { "lib": ["esnext"], - "strict": true, "allowJs": false, "noImplicitAny": true, - "noUnusedLocals": false, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", "types": [] }, } diff --git a/packages/icons/tsconfig.json b/packages/icons/tsconfig.json index 0c6beeacae..8995f295a6 100644 --- a/packages/icons/tsconfig.json +++ b/packages/icons/tsconfig.json @@ -1,20 +1,8 @@ { "extends": "../ts/tsconfig.json", "compilerOptions": { - "strict": true, "allowJs": false, "noImplicitAny": true, - "noUnusedLocals": false, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", "outDir": "dist", - "declaration": true }, } \ No newline at end of file diff --git a/packages/launcher/__snapshots__/browsers_spec.ts.js b/packages/launcher/__snapshots__/browsers_spec.ts.js index f01ee6d7b9..b44419587a 100644 --- a/packages/launcher/__snapshots__/browsers_spec.ts.js +++ b/packages/launcher/__snapshots__/browsers_spec.ts.js @@ -11,17 +11,6 @@ exports['browsers returns the expected list of browsers 1'] = [ 'google-chrome-stable', ], }, - { - 'name': 'chromium', - 'family': 'chromium', - 'channel': 'stable', - 'displayName': 'Chromium', - 'versionRegex': {}, - 'binary': [ - 'chromium-browser', - 'chromium', - ], - }, { 'name': 'chrome', 'family': 'chromium', @@ -34,10 +23,29 @@ exports['browsers returns the expected list of browsers 1'] = [ 'name': 'chrome', 'family': 'chromium', 'channel': 'canary', - 'displayName': 'Canary', + 'displayName': 'Chrome Canary', 'versionRegex': {}, 'binary': 'google-chrome-canary', }, + { + 'name': 'chrome-for-testing', + 'family': 'chromium', + 'channel': 'stable', + 'displayName': 'Chrome for Testing', + 'versionRegex': {}, + 'binary': 'chrome', + }, + { + 'name': 'chromium', + 'family': 'chromium', + 'channel': 'stable', + 'displayName': 'Chromium', + 'versionRegex': {}, + 'binary': [ + 'chromium-browser', + 'chromium', + ], + }, { 'name': 'firefox', 'family': 'firefox', @@ -79,17 +87,6 @@ exports['browsers returns the expected list of browsers 1'] = [ 'microsoft-edge', ], }, - { - 'name': 'edge', - 'family': 'chromium', - 'channel': 'canary', - 'displayName': 'Edge Canary', - 'versionRegex': {}, - 'binary': [ - 'edge-canary', - 'microsoft-edge-canary', - ], - }, { 'name': 'edge', 'family': 'chromium', @@ -101,6 +98,17 @@ exports['browsers returns the expected list of browsers 1'] = [ 'microsoft-edge-beta', ], }, + { + 'name': 'edge', + 'family': 'chromium', + 'channel': 'canary', + 'displayName': 'Edge Canary', + 'versionRegex': {}, + 'binary': [ + 'edge-canary', + 'microsoft-edge-canary', + ], + }, { 'name': 'edge', 'family': 'chromium', diff --git a/packages/launcher/__snapshots__/darwin_spec.ts.js b/packages/launcher/__snapshots__/darwin_spec.ts.js index 2043be0ce3..8b20e11f91 100644 --- a/packages/launcher/__snapshots__/darwin_spec.ts.js +++ b/packages/launcher/__snapshots__/darwin_spec.ts.js @@ -15,10 +15,58 @@ exports['darwin browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Google Chrome.app', 'executable': 'Contents/MacOS/Google Chrome', - 'appId': 'com.google.Chrome', + 'bundleId': 'com.google.Chrome', 'versionProperty': 'KSVersion', }, }, + { + 'name': 'chrome', + 'family': 'chromium', + 'channel': 'beta', + 'displayName': 'Chrome Beta', + 'versionRegex': {}, + 'binary': 'google-chrome-beta', + 'path': '/Applications/Google Chrome Beta.app/Contents/MacOS/Google Chrome Beta', + 'version': 'someVersion', + 'findAppParams': { + 'appName': 'Google Chrome Beta.app', + 'executable': 'Contents/MacOS/Google Chrome Beta', + 'bundleId': 'com.google.Chrome.beta', + 'versionProperty': 'KSVersion', + }, + }, + { + 'name': 'chrome', + 'family': 'chromium', + 'channel': 'canary', + 'displayName': 'Chrome Canary', + 'versionRegex': {}, + 'binary': 'google-chrome-canary', + 'path': '/Applications/Google Chrome Canary.app/Contents/MacOS/Google Chrome Canary', + 'version': 'someVersion', + 'findAppParams': { + 'appName': 'Google Chrome Canary.app', + 'executable': 'Contents/MacOS/Google Chrome Canary', + 'bundleId': 'com.google.Chrome.canary', + 'versionProperty': 'KSVersion', + }, + }, + { + 'name': 'chrome-for-testing', + 'family': 'chromium', + 'channel': 'stable', + 'displayName': 'Chrome for Testing', + 'versionRegex': {}, + 'binary': 'chrome', + 'path': '/Applications/Google Chrome for Testing.app/Contents/MacOS/Google Chrome for Testing', + 'version': 'someVersion', + 'findAppParams': { + 'appName': 'Google Chrome for Testing.app', + 'executable': 'Contents/MacOS/Google Chrome for Testing', + 'bundleId': 'com.google.chrome.for.testing', + 'versionProperty': 'CFBundleShortVersionString', + }, + }, { 'name': 'chromium', 'family': 'chromium', @@ -34,42 +82,10 @@ exports['darwin browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Chromium.app', 'executable': 'Contents/MacOS/Chromium', - 'appId': 'org.chromium.Chromium', + 'bundleId': 'org.chromium.Chromium', 'versionProperty': 'CFBundleShortVersionString', }, }, - { - 'name': 'chrome', - 'family': 'chromium', - 'channel': 'beta', - 'displayName': 'Chrome Beta', - 'versionRegex': {}, - 'binary': 'google-chrome-beta', - 'path': '/Applications/Google Chrome Beta.app/Contents/MacOS/Google Chrome Beta', - 'version': 'someVersion', - 'findAppParams': { - 'appName': 'Google Chrome Beta.app', - 'executable': 'Contents/MacOS/Google Chrome Beta', - 'appId': 'com.google.Chrome.beta', - 'versionProperty': 'KSVersion', - }, - }, - { - 'name': 'chrome', - 'family': 'chromium', - 'channel': 'canary', - 'displayName': 'Canary', - 'versionRegex': {}, - 'binary': 'google-chrome-canary', - 'path': '/Applications/Google Chrome Canary.app/Contents/MacOS/Google Chrome Canary', - 'version': 'someVersion', - 'findAppParams': { - 'appName': 'Google Chrome Canary.app', - 'executable': 'Contents/MacOS/Google Chrome Canary', - 'appId': 'com.google.Chrome.canary', - 'versionProperty': 'KSVersion', - }, - }, { 'name': 'firefox', 'family': 'firefox', @@ -82,7 +98,7 @@ exports['darwin browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Firefox.app', 'executable': 'Contents/MacOS/firefox', - 'appId': 'org.mozilla.firefox', + 'bundleId': 'org.mozilla.firefox', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -101,7 +117,7 @@ exports['darwin browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Firefox Developer Edition.app', 'executable': 'Contents/MacOS/firefox', - 'appId': 'org.mozilla.firefoxdeveloperedition', + 'bundleId': 'org.mozilla.firefoxdeveloperedition', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -120,7 +136,7 @@ exports['darwin browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Firefox Nightly.app', 'executable': 'Contents/MacOS/firefox', - 'appId': 'org.mozilla.nightly', + 'bundleId': 'org.mozilla.nightly', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -139,26 +155,7 @@ exports['darwin browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Microsoft Edge.app', 'executable': 'Contents/MacOS/Microsoft Edge', - 'appId': 'com.microsoft.Edge', - 'versionProperty': 'CFBundleShortVersionString', - }, - }, - { - 'name': 'edge', - 'family': 'chromium', - 'channel': 'canary', - 'displayName': 'Edge Canary', - 'versionRegex': {}, - 'binary': [ - 'edge-canary', - 'microsoft-edge-canary', - ], - 'path': '/Applications/Microsoft Edge Canary.app/Contents/MacOS/Microsoft Edge Canary', - 'version': 'someVersion', - 'findAppParams': { - 'appName': 'Microsoft Edge Canary.app', - 'executable': 'Contents/MacOS/Microsoft Edge Canary', - 'appId': 'com.microsoft.Edge.Canary', + 'bundleId': 'com.microsoft.Edge', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -177,7 +174,26 @@ exports['darwin browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Microsoft Edge Beta.app', 'executable': 'Contents/MacOS/Microsoft Edge Beta', - 'appId': 'com.microsoft.Edge.Beta', + 'bundleId': 'com.microsoft.Edge.Beta', + 'versionProperty': 'CFBundleShortVersionString', + }, + }, + { + 'name': 'edge', + 'family': 'chromium', + 'channel': 'canary', + 'displayName': 'Edge Canary', + 'versionRegex': {}, + 'binary': [ + 'edge-canary', + 'microsoft-edge-canary', + ], + 'path': '/Applications/Microsoft Edge Canary.app/Contents/MacOS/Microsoft Edge Canary', + 'version': 'someVersion', + 'findAppParams': { + 'appName': 'Microsoft Edge Canary.app', + 'executable': 'Contents/MacOS/Microsoft Edge Canary', + 'bundleId': 'com.microsoft.Edge.Canary', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -196,7 +212,7 @@ exports['darwin browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Microsoft Edge Dev.app', 'executable': 'Contents/MacOS/Microsoft Edge Dev', - 'appId': 'com.microsoft.Edge.Dev', + 'bundleId': 'com.microsoft.Edge.Dev', 'versionProperty': 'CFBundleShortVersionString', }, }, diff --git a/packages/launcher/__snapshots__/windows_spec.ts.js b/packages/launcher/__snapshots__/windows_spec.ts.js index 02a57883f1..e19dd43f79 100644 --- a/packages/launcher/__snapshots__/windows_spec.ts.js +++ b/packages/launcher/__snapshots__/windows_spec.ts.js @@ -15,10 +15,58 @@ exports['windows browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Google Chrome.app', 'executable': 'Contents/MacOS/Google Chrome', - 'appId': 'com.google.Chrome', + 'bundleId': 'com.google.Chrome', 'versionProperty': 'KSVersion', }, }, + { + 'name': 'chrome', + 'family': 'chromium', + 'channel': 'beta', + 'displayName': 'Chrome Beta', + 'versionRegex': {}, + 'binary': 'google-chrome-beta', + 'path': 'C:/Program Files (x86)/Google/Chrome Beta/Application/chrome.exe', + 'version': '6.7.8', + 'findAppParams': { + 'appName': 'Google Chrome Beta.app', + 'executable': 'Contents/MacOS/Google Chrome Beta', + 'bundleId': 'com.google.Chrome.beta', + 'versionProperty': 'KSVersion', + }, + }, + { + 'name': 'chrome', + 'family': 'chromium', + 'channel': 'canary', + 'displayName': 'Chrome Canary', + 'versionRegex': {}, + 'binary': 'google-chrome-canary', + 'path': 'C:/Users/flotwig/AppData/Local/Google/Chrome SxS/Application/chrome.exe', + 'version': '3.4.5', + 'findAppParams': { + 'appName': 'Google Chrome Canary.app', + 'executable': 'Contents/MacOS/Google Chrome Canary', + 'bundleId': 'com.google.Chrome.canary', + 'versionProperty': 'KSVersion', + }, + }, + { + 'name': 'chrome-for-testing', + 'family': 'chromium', + 'channel': 'stable', + 'displayName': 'Chrome for Testing', + 'versionRegex': {}, + 'binary': 'chrome', + 'path': 'C:/Program Files/Google/Chrome for Testing/chrome.exe', + 'version': '1.2.3', + 'findAppParams': { + 'appName': 'Google Chrome for Testing.app', + 'executable': 'Contents/MacOS/Google Chrome for Testing', + 'bundleId': 'com.google.chrome.for.testing', + 'versionProperty': 'CFBundleShortVersionString', + }, + }, { 'name': 'chromium', 'family': 'chromium', @@ -34,42 +82,10 @@ exports['windows browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Chromium.app', 'executable': 'Contents/MacOS/Chromium', - 'appId': 'org.chromium.Chromium', + 'bundleId': 'org.chromium.Chromium', 'versionProperty': 'CFBundleShortVersionString', }, }, - { - 'name': 'chrome', - 'family': 'chromium', - 'channel': 'beta', - 'displayName': 'Chrome Beta', - 'versionRegex': {}, - 'binary': 'google-chrome-beta', - 'path': 'C:/Program Files (x86)/Google/Chrome Beta/Application/chrome.exe', - 'version': '6.7.8', - 'findAppParams': { - 'appName': 'Google Chrome Beta.app', - 'executable': 'Contents/MacOS/Google Chrome Beta', - 'appId': 'com.google.Chrome.beta', - 'versionProperty': 'KSVersion', - }, - }, - { - 'name': 'chrome', - 'family': 'chromium', - 'channel': 'canary', - 'displayName': 'Canary', - 'versionRegex': {}, - 'binary': 'google-chrome-canary', - 'path': 'C:/Users/flotwig/AppData/Local/Google/Chrome SxS/Application/chrome.exe', - 'version': '3.4.5', - 'findAppParams': { - 'appName': 'Google Chrome Canary.app', - 'executable': 'Contents/MacOS/Google Chrome Canary', - 'appId': 'com.google.Chrome.canary', - 'versionProperty': 'KSVersion', - }, - }, { 'name': 'firefox', 'family': 'firefox', @@ -82,7 +98,7 @@ exports['windows browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Firefox.app', 'executable': 'Contents/MacOS/firefox', - 'appId': 'org.mozilla.firefox', + 'bundleId': 'org.mozilla.firefox', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -101,7 +117,7 @@ exports['windows browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Firefox Developer Edition.app', 'executable': 'Contents/MacOS/firefox', - 'appId': 'org.mozilla.firefoxdeveloperedition', + 'bundleId': 'org.mozilla.firefoxdeveloperedition', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -120,7 +136,7 @@ exports['windows browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Firefox Nightly.app', 'executable': 'Contents/MacOS/firefox', - 'appId': 'org.mozilla.nightly', + 'bundleId': 'org.mozilla.nightly', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -139,26 +155,7 @@ exports['windows browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Microsoft Edge.app', 'executable': 'Contents/MacOS/Microsoft Edge', - 'appId': 'com.microsoft.Edge', - 'versionProperty': 'CFBundleShortVersionString', - }, - }, - { - 'name': 'edge', - 'family': 'chromium', - 'channel': 'canary', - 'displayName': 'Edge Canary', - 'versionRegex': {}, - 'binary': [ - 'edge-canary', - 'microsoft-edge-canary', - ], - 'path': 'C:/Users/flotwig/AppData/Local/Microsoft/Edge SxS/Application/msedge.exe', - 'version': '14', - 'findAppParams': { - 'appName': 'Microsoft Edge Canary.app', - 'executable': 'Contents/MacOS/Microsoft Edge Canary', - 'appId': 'com.microsoft.Edge.Canary', + 'bundleId': 'com.microsoft.Edge', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -177,7 +174,26 @@ exports['windows browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Microsoft Edge Beta.app', 'executable': 'Contents/MacOS/Microsoft Edge Beta', - 'appId': 'com.microsoft.Edge.Beta', + 'bundleId': 'com.microsoft.Edge.Beta', + 'versionProperty': 'CFBundleShortVersionString', + }, + }, + { + 'name': 'edge', + 'family': 'chromium', + 'channel': 'canary', + 'displayName': 'Edge Canary', + 'versionRegex': {}, + 'binary': [ + 'edge-canary', + 'microsoft-edge-canary', + ], + 'path': 'C:/Users/flotwig/AppData/Local/Microsoft/Edge SxS/Application/msedge.exe', + 'version': '14', + 'findAppParams': { + 'appName': 'Microsoft Edge Canary.app', + 'executable': 'Contents/MacOS/Microsoft Edge Canary', + 'bundleId': 'com.microsoft.Edge.Canary', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -196,25 +212,75 @@ exports['windows browser detection detects browsers as expected 1'] = [ 'findAppParams': { 'appName': 'Microsoft Edge Dev.app', 'executable': 'Contents/MacOS/Microsoft Edge Dev', - 'appId': 'com.microsoft.Edge.Dev', + 'bundleId': 'com.microsoft.Edge.Dev', 'versionProperty': 'CFBundleShortVersionString', }, }, ] -exports['windows browser detection detects 64-bit Chrome Beta app path 1'] = { - 'name': 'chrome', - 'version': '9.0.1', - 'path': 'C:/Program Files/Google/Chrome Beta/Application/chrome.exe', -} +exports['windows browser detection detects Chrome Beta 64-bit install 1'] = [ + { + 'name': 'chrome', + 'family': 'chromium', + 'channel': 'beta', + 'displayName': 'Chrome Beta', + 'versionRegex': {}, + 'binary': 'google-chrome-beta', + 'minSupportedVersion': 64, + 'path': 'C:/Program Files/Google/Chrome Beta/Application/chrome.exe', + 'version': '9.0.1', + 'findAppParams': { + 'appName': 'Google Chrome Beta.app', + 'executable': 'Contents/MacOS/Google Chrome Beta', + 'bundleId': 'com.google.Chrome.beta', + 'versionProperty': 'KSVersion', + }, + }, +] -exports['windows browser detection detects new Chrome 64-bit app path 1'] = { - 'name': 'chrome', - 'version': '4.4.4', - 'path': 'C:/Program Files/Google/Chrome/Application/chrome.exe', -} +exports['windows browser detection detects Chrome 64-bit install 1'] = [ + { + 'name': 'chrome', + 'family': 'chromium', + 'channel': 'stable', + 'displayName': 'Chrome', + 'versionRegex': {}, + 'binary': [ + 'google-chrome', + 'chrome', + 'google-chrome-stable', + ], + 'path': 'C:/Program Files/Google/Chrome/Application/chrome.exe', + 'version': '4.4.4', + 'findAppParams': { + 'appName': 'Google Chrome.app', + 'executable': 'Contents/MacOS/Google Chrome', + 'bundleId': 'com.google.Chrome', + 'versionProperty': 'KSVersion', + }, + }, +] -exports['windows browser detection detects local Firefox installs 1'] = [ +exports['windows browser detection detects Chrome for Testing 32-bit install 1'] = [ + { + 'name': 'chrome-for-testing', + 'family': 'chromium', + 'channel': 'stable', + 'displayName': 'Chrome for Testing', + 'versionRegex': {}, + 'binary': 'chrome', + 'path': 'C:/Program Files (x86)/Google/Chrome for Testing/chrome.exe', + 'version': '5.5.5', + 'findAppParams': { + 'appName': 'Google Chrome for Testing.app', + 'executable': 'Contents/MacOS/Google Chrome for Testing', + 'bundleId': 'com.google.chrome.for.testing', + 'versionProperty': 'CFBundleShortVersionString', + }, + }, +] + +exports['windows browser detection detects Firefox local installs 1'] = [ { 'name': 'firefox', 'family': 'firefox', @@ -227,7 +293,7 @@ exports['windows browser detection detects local Firefox installs 1'] = [ 'findAppParams': { 'appName': 'Firefox.app', 'executable': 'Contents/MacOS/firefox', - 'appId': 'org.mozilla.firefox', + 'bundleId': 'org.mozilla.firefox', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -246,7 +312,7 @@ exports['windows browser detection detects local Firefox installs 1'] = [ 'findAppParams': { 'appName': 'Firefox Developer Edition.app', 'executable': 'Contents/MacOS/firefox', - 'appId': 'org.mozilla.firefoxdeveloperedition', + 'bundleId': 'org.mozilla.firefoxdeveloperedition', 'versionProperty': 'CFBundleShortVersionString', }, }, @@ -265,7 +331,73 @@ exports['windows browser detection detects local Firefox installs 1'] = [ 'findAppParams': { 'appName': 'Firefox Nightly.app', 'executable': 'Contents/MacOS/firefox', - 'appId': 'org.mozilla.nightly', + 'bundleId': 'org.mozilla.nightly', + 'versionProperty': 'CFBundleShortVersionString', + }, + }, +] + +exports['windows browser detection detects Chromium 64-bit install 1'] = [ + { + 'name': 'chromium', + 'family': 'chromium', + 'channel': 'stable', + 'displayName': 'Chromium', + 'versionRegex': {}, + 'binary': [ + 'chromium-browser', + 'chromium', + ], + 'path': 'C:/Program Files/Google/chrome-win/chrome.exe', + 'version': '6.6.6', + 'findAppParams': { + 'appName': 'Chromium.app', + 'executable': 'Contents/MacOS/Chromium', + 'bundleId': 'org.chromium.Chromium', + 'versionProperty': 'CFBundleShortVersionString', + }, + }, +] + +exports['windows browser detection detects Chromium 32-bit install in Chromium folder 1'] = [ + { + 'name': 'chromium', + 'family': 'chromium', + 'channel': 'stable', + 'displayName': 'Chromium', + 'versionRegex': {}, + 'binary': [ + 'chromium-browser', + 'chromium', + ], + 'path': 'C:/Program Files (x86)/Google/Chromium/chrome.exe', + 'version': '7.7.7', + 'findAppParams': { + 'appName': 'Chromium.app', + 'executable': 'Contents/MacOS/Chromium', + 'bundleId': 'org.chromium.Chromium', + 'versionProperty': 'CFBundleShortVersionString', + }, + }, +] + +exports['windows browser detection detects Chromium 64-bit install in Chromium folder 1'] = [ + { + 'name': 'chromium', + 'family': 'chromium', + 'channel': 'stable', + 'displayName': 'Chromium', + 'versionRegex': {}, + 'binary': [ + 'chromium-browser', + 'chromium', + ], + 'path': 'C:/Program Files/Google/Chromium/chrome.exe', + 'version': '8.8.8', + 'findAppParams': { + 'appName': 'Chromium.app', + 'executable': 'Contents/MacOS/Chromium', + 'bundleId': 'org.chromium.Chromium', 'versionProperty': 'CFBundleShortVersionString', }, }, diff --git a/packages/launcher/lib/darwin/index.ts b/packages/launcher/lib/darwin/index.ts index caa2500839..8d4f7ee06c 100644 --- a/packages/launcher/lib/darwin/index.ts +++ b/packages/launcher/lib/darwin/index.ts @@ -17,27 +17,35 @@ export const browsers: Detectors = { stable: { appName: 'Google Chrome.app', executable: 'Contents/MacOS/Google Chrome', - appId: 'com.google.Chrome', + bundleId: 'com.google.Chrome', versionProperty: 'KSVersion', }, beta: { appName: 'Google Chrome Beta.app', executable: 'Contents/MacOS/Google Chrome Beta', - appId: 'com.google.Chrome.beta', + bundleId: 'com.google.Chrome.beta', versionProperty: 'KSVersion', }, canary: { appName: 'Google Chrome Canary.app', executable: 'Contents/MacOS/Google Chrome Canary', - appId: 'com.google.Chrome.canary', + bundleId: 'com.google.Chrome.canary', versionProperty: 'KSVersion', }, }, + 'chrome-for-testing': { + stable: { + appName: 'Google Chrome for Testing.app', + executable: 'Contents/MacOS/Google Chrome for Testing', + bundleId: 'com.google.chrome.for.testing', + versionProperty: 'CFBundleShortVersionString', + }, + }, chromium: { stable: { appName: 'Chromium.app', executable: 'Contents/MacOS/Chromium', - appId: 'org.chromium.Chromium', + bundleId: 'org.chromium.Chromium', versionProperty: 'CFBundleShortVersionString', }, }, @@ -45,19 +53,19 @@ export const browsers: Detectors = { stable: { appName: 'Firefox.app', executable: 'Contents/MacOS/firefox', - appId: 'org.mozilla.firefox', + bundleId: 'org.mozilla.firefox', versionProperty: 'CFBundleShortVersionString', }, dev: { appName: 'Firefox Developer Edition.app', executable: 'Contents/MacOS/firefox', - appId: 'org.mozilla.firefoxdeveloperedition', + bundleId: 'org.mozilla.firefoxdeveloperedition', versionProperty: 'CFBundleShortVersionString', }, nightly: { appName: 'Firefox Nightly.app', executable: 'Contents/MacOS/firefox', - appId: 'org.mozilla.nightly', + bundleId: 'org.mozilla.nightly', versionProperty: 'CFBundleShortVersionString', }, }, @@ -65,25 +73,25 @@ export const browsers: Detectors = { stable: { appName: 'Microsoft Edge.app', executable: 'Contents/MacOS/Microsoft Edge', - appId: 'com.microsoft.Edge', - versionProperty: 'CFBundleShortVersionString', - }, - canary: { - appName: 'Microsoft Edge Canary.app', - executable: 'Contents/MacOS/Microsoft Edge Canary', - appId: 'com.microsoft.Edge.Canary', + bundleId: 'com.microsoft.Edge', versionProperty: 'CFBundleShortVersionString', }, beta: { appName: 'Microsoft Edge Beta.app', executable: 'Contents/MacOS/Microsoft Edge Beta', - appId: 'com.microsoft.Edge.Beta', + bundleId: 'com.microsoft.Edge.Beta', + versionProperty: 'CFBundleShortVersionString', + }, + canary: { + appName: 'Microsoft Edge Canary.app', + executable: 'Contents/MacOS/Microsoft Edge Canary', + bundleId: 'com.microsoft.Edge.Canary', versionProperty: 'CFBundleShortVersionString', }, dev: { appName: 'Microsoft Edge Dev.app', executable: 'Contents/MacOS/Microsoft Edge Dev', - appId: 'com.microsoft.Edge.Dev', + bundleId: 'com.microsoft.Edge.Dev', versionProperty: 'CFBundleShortVersionString', }, }, diff --git a/packages/launcher/lib/darwin/util.ts b/packages/launcher/lib/darwin/util.ts index e669682ef3..2e87bc4b70 100644 --- a/packages/launcher/lib/darwin/util.ts +++ b/packages/launcher/lib/darwin/util.ts @@ -64,9 +64,13 @@ export type AppInfo = { } export type FindAppParams = { + // The name of the application (e.g. 'Google Chrome.app') appName: string + // The path to the executable within the application (e.g. 'Contents/MacOS/Google Chrome') executable: string - appId: string + // The CFBundleIdentifier in the Info.plist (e.g. 'com.google.Chrome') + bundleId: string + // The key from the Info.plist to find the version (e.g. 'KSVersion') versionProperty: string } @@ -75,8 +79,8 @@ function formApplicationPath (appName: string) { } /** finds an application and its version */ -export function findApp ({ appName, executable, appId, versionProperty }: FindAppParams): Promise { - debugVerbose('looking for app %s id %s', executable, appId) +export function findApp ({ appName, executable, bundleId, versionProperty }: FindAppParams): Promise { + debugVerbose('looking for app %s bundle id %s', executable, bundleId) const findVersion = (foundPath: string) => { return parsePlist(foundPath, versionProperty).then((version) => { @@ -90,7 +94,7 @@ export function findApp ({ appName, executable, appId, versionProperty }: FindAp } const tryMdFind = () => { - return mdfind(appId).then(findVersion) + return mdfind(bundleId).then(findVersion) } const tryFullApplicationFind = () => { diff --git a/packages/launcher/lib/known-browsers.ts b/packages/launcher/lib/known-browsers.ts index 5b6f9bdd12..0d1fa044fa 100644 --- a/packages/launcher/lib/known-browsers.ts +++ b/packages/launcher/lib/known-browsers.ts @@ -7,7 +7,7 @@ export const knownBrowsers: Browser[] = [ family: 'chromium', channel: 'stable', displayName: 'Chrome', - versionRegex: /Google Chrome (\S+)/m, + versionRegex: /Google Chrome(?! for Testing) (\S+)/m, binary: ['google-chrome', 'chrome', 'google-chrome-stable'], validator: (browser: FoundBrowser, platform: NodeJS.Platform): BrowserValidatorResult => { // a validator method can be defined to mark a browser as unsupported @@ -24,15 +24,6 @@ export const knownBrowsers: Browser[] = [ } }, }, - { - name: 'chromium', - family: 'chromium', - // technically Chromium is always in development - channel: 'stable', - displayName: 'Chromium', - versionRegex: /Chromium (\S+)/m, - binary: ['chromium-browser', 'chromium'], - }, { name: 'chrome', family: 'chromium', @@ -45,10 +36,27 @@ export const knownBrowsers: Browser[] = [ name: 'chrome', family: 'chromium', channel: 'canary', - displayName: 'Canary', + displayName: 'Chrome Canary', versionRegex: /Google Chrome Canary (\S+)/m, binary: 'google-chrome-canary', }, + { + name: 'chrome-for-testing', + family: 'chromium', + channel: 'stable', + displayName: 'Chrome for Testing', + versionRegex: /Google Chrome for Testing (\S+)/m, + binary: 'chrome', + }, + { + name: 'chromium', + family: 'chromium', + // technically Chromium is always in development + channel: 'stable', + displayName: 'Chromium', + versionRegex: /Chromium (\S+)/m, + binary: ['chromium-browser', 'chromium'], + }, { name: 'firefox', family: 'firefox', @@ -86,14 +94,6 @@ export const knownBrowsers: Browser[] = [ versionRegex: /Microsoft Edge (\S+)/mi, binary: ['edge', 'microsoft-edge'], }, - { - name: 'edge', - family: 'chromium', - channel: 'canary', - displayName: 'Edge Canary', - versionRegex: /Microsoft Edge.+?(\S*(?= canary)|(?<=canary )\S*)/mi, - binary: ['edge-canary', 'microsoft-edge-canary'], - }, { name: 'edge', family: 'chromium', @@ -102,6 +102,14 @@ export const knownBrowsers: Browser[] = [ versionRegex: /Microsoft Edge.+?(\S*(?= beta)|(?<=beta )\S*)/mi, binary: ['edge-beta', 'microsoft-edge-beta'], }, + { + name: 'edge', + family: 'chromium', + channel: 'canary', + displayName: 'Edge Canary', + versionRegex: /Microsoft Edge.+?(\S*(?= canary)|(?<=canary )\S*)/mi, + binary: ['edge-canary', 'microsoft-edge-canary'], + }, { name: 'edge', family: 'chromium', diff --git a/packages/launcher/lib/windows/index.ts b/packages/launcher/lib/windows/index.ts index d0baaedbac..c1897b6742 100644 --- a/packages/launcher/lib/windows/index.ts +++ b/packages/launcher/lib/windows/index.ts @@ -26,9 +26,12 @@ function formChromeBetaAppPath () { } function formChromiumAppPath () { - const exe = 'C:/Program Files (x86)/Google/chrome-win32/chrome.exe' - - return [normalize(exe)] + return [ + 'C:/Program Files (x86)/Google/chrome-win32/chrome.exe', + 'C:/Program Files/Google/chrome-win/chrome.exe', + 'C:/Program Files/Google/Chromium/chrome.exe', + 'C:/Program Files (x86)/Google/Chromium/chrome.exe', + ].map(normalize) } function formChromeCanaryAppPath () { @@ -46,6 +49,13 @@ function formChromeCanaryAppPath () { return [normalize(exe)] } +function formChromeForTestingAppPath () { + return [ + 'C:/Program Files/Google/Chrome for Testing/chrome.exe', + 'C:/Program Files (x86)/Google/Chrome for Testing/chrome.exe', + ].map(normalize) +} + function getFirefoxPaths (editionFolder) { return () => { return (['Program Files', 'Program Files (x86)']) @@ -91,6 +101,9 @@ const formPaths: WindowsBrowserPaths = { beta: formChromeBetaAppPath, canary: formChromeCanaryAppPath, }, + 'chrome-for-testing': { + stable: formChromeForTestingAppPath, + }, chromium: { stable: formChromiumAppPath, }, @@ -106,10 +119,10 @@ const formPaths: WindowsBrowserPaths = { beta: () => { return [normalize('C:/Program Files (x86)/Microsoft/Edge Beta/Application/msedge.exe')] }, + canary: formEdgeCanaryAppPath, dev: () => { return [normalize('C:/Program Files (x86)/Microsoft/Edge Dev/Application/msedge.exe')] }, - canary: formEdgeCanaryAppPath, }, } diff --git a/packages/launcher/test/unit/darwin_spec.ts b/packages/launcher/test/unit/darwin_spec.ts index d62101d27b..0e03b11904 100644 --- a/packages/launcher/test/unit/darwin_spec.ts +++ b/packages/launcher/test/unit/darwin_spec.ts @@ -30,7 +30,7 @@ function generatePlist (key, value) { function stubBrowser (findAppParams: darwinUtil.FindAppParams) { (utils.getOutput as unknown as SinonStub) - .withArgs(`mdfind 'kMDItemCFBundleIdentifier=="${findAppParams.appId}"' | head -1`) + .withArgs(`mdfind 'kMDItemCFBundleIdentifier=="${findAppParams.bundleId}"' | head -1`) .resolves({ stdout: `/Applications/${findAppParams.appName}` }) ;(fse.readFile as SinonStub) diff --git a/packages/launcher/test/unit/windows_spec.ts b/packages/launcher/test/unit/windows_spec.ts index 27b826fe99..af321beca6 100644 --- a/packages/launcher/test/unit/windows_spec.ts +++ b/packages/launcher/test/unit/windows_spec.ts @@ -43,12 +43,20 @@ describe('windows browser detection', () => { }) it('detects browsers as expected', async () => { + // chrome stubBrowser('C:/Program Files (x86)/Google/Chrome/Application/chrome.exe', '1.2.3') + // chromium - 32-bit will be preferred for passivity stubBrowser('C:/Program Files (x86)/Google/chrome-win32/chrome.exe', '2.3.4') + stubBrowser('C:/Program Files/Google/chrome-win/chrome.exe', '2.3.4') + // chrome-for-testing - 64-bit will be preferred + stubBrowser('C:/Program Files (x86)/Google/Chrome for Testing/chrome.exe', '1.2.3') + stubBrowser('C:/Program Files/Google/Chrome for Testing/chrome.exe', '1.2.3') + + // chrome beta stubBrowser('C:/Program Files (x86)/Google/Chrome Beta/Application/chrome.exe', '6.7.8') - // canary is installed in homedir + // chrome canary is installed in homedir stubBrowser(`${HOMEDIR}/AppData/Local/Google/Chrome SxS/Application/chrome.exe`, '3.4.5') // have 32-bit and 64-bit ff - 64-bit will be preferred @@ -71,23 +79,30 @@ describe('windows browser detection', () => { snapshot(await detect(knownBrowsers)) }) - it('detects 64-bit Chrome Beta app path', async () => { + it('detects Chrome Beta 64-bit install', async () => { stubBrowser('C:/Program Files/Google/Chrome Beta/Application/chrome.exe', '9.0.1') - const chrome = _.find(knownBrowsers, { name: 'chrome', channel: 'beta' }) + const chrome = _.find(knownBrowsers, { name: 'chrome', channel: 'beta' })! - snapshot(await windowsHelper.detect(chrome)) + snapshot(await detect([chrome])) }) // @see https://github.com/cypress-io/cypress/issues/8425 - it('detects new Chrome 64-bit app path', async () => { + it('detects Chrome 64-bit install', async () => { stubBrowser('C:/Program Files/Google/Chrome/Application/chrome.exe', '4.4.4') - const chrome = _.find(knownBrowsers, { name: 'chrome', channel: 'stable' }) + const chrome = _.find(knownBrowsers, { name: 'chrome', channel: 'stable' })! - snapshot(await windowsHelper.detect(chrome)) + snapshot(await detect([chrome])) + }) + + it('detects Chrome for Testing 32-bit install', async () => { + stubBrowser('C:/Program Files (x86)/Google/Chrome for Testing/chrome.exe', '5.5.5') + const chromeForTesting = _.find(knownBrowsers, { name: 'chrome-for-testing' })! + + snapshot(await detect([chromeForTesting])) }) // @see https://github.com/cypress-io/cypress/issues/8432 - it('detects local Firefox installs', async () => { + it('detects Firefox local installs', async () => { stubBrowser(`${HOMEDIR}/AppData/Local/Mozilla Firefox/firefox.exe`, '100') stubBrowser(`${HOMEDIR}/AppData/Local/Firefox Nightly/firefox.exe`, '200') stubBrowser(`${HOMEDIR}/AppData/Local/Firefox Developer Edition/firefox.exe`, '300') @@ -97,6 +112,27 @@ describe('windows browser detection', () => { snapshot(await detect(firefoxes)) }) + it('detects Chromium 64-bit install', async () => { + stubBrowser('C:/Program Files/Google/chrome-win/chrome.exe', '6.6.6') + const chromium = _.find(knownBrowsers, { name: 'chromium' })! + + snapshot(await detect([chromium])) + }) + + it('detects Chromium 32-bit install in Chromium folder', async () => { + stubBrowser('C:/Program Files (x86)/Google/Chromium/chrome.exe', '7.7.7') + const chromium = _.find(knownBrowsers, { name: 'chromium' })! + + snapshot(await detect([chromium])) + }) + + it('detects Chromium 64-bit install in Chromium folder', async () => { + stubBrowser('C:/Program Files/Google/Chromium/chrome.exe', '8.8.8') + const chromium = _.find(knownBrowsers, { name: 'chromium' })! + + snapshot(await detect([chromium])) + }) + it('works with :browserName format in Windows', () => { sinon.stub(os, 'platform').returns('win32') let path = `${HOMEDIR}/foo/bar/browser.exe` diff --git a/packages/launcher/tsconfig.json b/packages/launcher/tsconfig.json index 22cbe18d5c..41c9480108 100644 --- a/packages/launcher/tsconfig.json +++ b/packages/launcher/tsconfig.json @@ -5,7 +5,6 @@ "./index.ts" ], "compilerOptions": { - "skipLibCheck": true }, "files": [ "./../ts/index.d.ts" diff --git a/packages/launchpad/cypress/e2e/choose-a-browser.cy.ts b/packages/launchpad/cypress/e2e/choose-a-browser.cy.ts index 94858029cc..cd3e4d42c7 100644 --- a/packages/launchpad/cypress/e2e/choose-a-browser.cy.ts +++ b/packages/launchpad/cypress/e2e/choose-a-browser.cy.ts @@ -46,7 +46,7 @@ describe('Choose a browser page', () => { cy.get('h1').should('contain', 'Choose a browser') - cy.findByRole('radio', { name: 'Edge v8', checked: true }) + cy.findByRole('radio', { name: 'Edge v9', checked: true }) cy.percySnapshot() @@ -103,8 +103,10 @@ describe('Choose a browser page', () => { // varies depending on platform if (Cypress.platform === 'win32') { cy.get('@AlertBody').find('code').eq(1).should('have.text', `win-version-info is unable to access file: \\${path.replaceAll('/', '\\')}`) - } else { + } else if (Cypress.platform === 'linux') { cy.get('@AlertBody').find('code').eq(1).should('have.text', `spawn ${path} ENOENT`) + } else { + cy.get('@AlertBody').find('code').eq(1).should('have.text', `Unable to find browser with path ${path}`) } cy.percySnapshot() @@ -127,11 +129,11 @@ describe('Choose a browser page', () => { cy.findByRole('radio', { name: 'Chrome v1' }) - cy.findByRole('radio', { name: 'Firefox v5' }) + cy.findByRole('radio', { name: 'Firefox v6' }) - cy.findByRole('radio', { name: 'Electron v12' }) + cy.findByRole('radio', { name: 'Electron v13' }) - cy.findByRole('radio', { name: 'Edge v8' }) + cy.findByRole('radio', { name: 'Edge v9' }) }) it('performs mutation to launch selected browser when launch button is pressed', () => { @@ -194,7 +196,7 @@ describe('Choose a browser page', () => { cy.get('h1').should('contain', 'Choose a browser') cy.findByRole('radio', { name: 'Chrome v1', checked: true }).as('chromeItem') - cy.findByRole('radio', { name: 'Firefox v5', checked: false }).as('firefoxItem') + cy.findByRole('radio', { name: 'Firefox v6', checked: false }).as('firefoxItem') cy.contains('button', 'Start E2E Testing in Chrome').should('be.visible') @@ -205,7 +207,7 @@ describe('Choose a browser page', () => { }) cy.findByRole('radio', { name: 'Chrome v1', checked: false }) - cy.findByRole('radio', { name: 'Firefox v5', checked: true }) + cy.findByRole('radio', { name: 'Firefox v6', checked: true }) cy.contains('button', 'Start E2E Testing in Firefox').should('be.visible') }) @@ -323,7 +325,7 @@ describe('Choose a browser page', () => { }) cy.contains('button', 'Start E2E Testing in Firefox').should('be.visible') - cy.findByRole('radio', { name: 'Firefox v5', checked: true }).should('be.visible') + cy.findByRole('radio', { name: 'Firefox v6', checked: true }).should('be.visible') }) it('should return to welcome screen if user modifies the config file to not include the current testing type and recover', () => { @@ -371,7 +373,7 @@ describe('Choose a browser page', () => { cy.get('[data-cy="open-browser-list"]').children().should('have.length', 1) - cy.findByRole('radio', { name: 'Electron v12', checked: true }) + cy.findByRole('radio', { name: 'Electron v13', checked: true }) cy.percySnapshot() }) }) diff --git a/packages/launchpad/cypress/e2e/project-setup.cy.ts b/packages/launchpad/cypress/e2e/project-setup.cy.ts index 6ebefc8b3f..02a3bd0ff7 100644 --- a/packages/launchpad/cypress/e2e/project-setup.cy.ts +++ b/packages/launchpad/cypress/e2e/project-setup.cy.ts @@ -61,9 +61,9 @@ describe('Launchpad: Setup Project', () => { cy.contains('Choose a browser', { timeout: 15000 }) cy.findByRole('radio', { name: 'Chrome v1' }) - cy.findByRole('radio', { name: 'Firefox v5' }) - cy.findByRole('radio', { name: 'Electron v12' }) - cy.findByRole('radio', { name: 'Edge v8' }) + cy.findByRole('radio', { name: 'Firefox v6' }) + cy.findByRole('radio', { name: 'Electron v13' }) + cy.findByRole('radio', { name: 'Edge v9' }) } beforeEach(() => { diff --git a/packages/launchpad/cypress/e2e/system-tests/config-spec.cy.ts b/packages/launchpad/cypress/e2e/system-tests/config-spec.cy.ts index 5bcf02a126..ec2355c043 100644 --- a/packages/launchpad/cypress/e2e/system-tests/config-spec.cy.ts +++ b/packages/launchpad/cypress/e2e/system-tests/config-spec.cy.ts @@ -4,7 +4,7 @@ describe('config-spec', () => { cy.findBrowsers() cy.openProject('plugin-filter-browsers', ['--e2e']) cy.withCtx(async (ctx) => { - expect(await ctx.browser.machineBrowsers()).to.have.length(12) // stubbed list of all browsers + expect(await ctx.browser.machineBrowsers()).to.have.length(13) // stubbed list of all browsers }) cy.visitLaunchpad() diff --git a/packages/reporter/tsconfig.json b/packages/reporter/tsconfig.json index 99b6a70b5b..be6c7cd941 100644 --- a/packages/reporter/tsconfig.json +++ b/packages/reporter/tsconfig.json @@ -1,7 +1,6 @@ { "extends": "../ts/tsconfig.json", "compilerOptions": { - "useDefineForClassFields": true, "types": [ "node", "cypress", diff --git a/packages/scaffold-config/tsconfig.json b/packages/scaffold-config/tsconfig.json index 935ec8b2ab..ae027f6500 100644 --- a/packages/scaffold-config/tsconfig.json +++ b/packages/scaffold-config/tsconfig.json @@ -10,19 +10,8 @@ ], "compilerOptions": { "lib": ["esnext"], - "strict": true, "allowJs": false, "noImplicitAny": true, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUnusedLocals": false, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", "types": [] } } \ No newline at end of file diff --git a/packages/server/__snapshots__/browsers_spec.js b/packages/server/__snapshots__/browsers_spec.js index 4d9e8283e3..f5992d0d36 100644 --- a/packages/server/__snapshots__/browsers_spec.js +++ b/packages/server/__snapshots__/browsers_spec.js @@ -7,7 +7,7 @@ Cypress supports the following browsers: - electron - chrome - chromium - - chrome:canary + - chrome-for-testing - edge - firefox @@ -28,7 +28,7 @@ Cypress supports the following browsers: - electron - chrome - chromium - - chrome:canary + - chrome-for-testing - edge - firefox diff --git a/packages/server/lib/automation/util.ts b/packages/server/lib/automation/util.ts index bc3caab879..baf04a9ec3 100644 --- a/packages/server/lib/automation/util.ts +++ b/packages/server/lib/automation/util.ts @@ -1,6 +1,7 @@ import type playwright from 'playwright-webkit' import { domainMatch } from 'tough-cookie' +// @ts-ignore export type CyCookie = Pick & { // use `undefined` instead of `unspecified` sameSite?: 'no_restriction' | 'lax' | 'strict' @@ -8,6 +9,7 @@ export type CyCookie = Pick { diff --git a/packages/server/lib/modes/interactive.ts b/packages/server/lib/modes/interactive.ts index c58dfa2a3e..bca0c83b11 100644 --- a/packages/server/lib/modes/interactive.ts +++ b/packages/server/lib/modes/interactive.ts @@ -125,6 +125,7 @@ export = { show: true, frame: true, transparent: false, + // @ts-ignore icon: image.createFromPath(cyIcons.getPathToIcon('icon_64x64.png')), }, } diff --git a/packages/server/lib/screenshots.js b/packages/server/lib/screenshots.ts similarity index 78% rename from packages/server/lib/screenshots.js rename to packages/server/lib/screenshots.ts index 79730f952a..8f68189c7a 100644 --- a/packages/server/lib/screenshots.js +++ b/packages/server/lib/screenshots.ts @@ -1,21 +1,74 @@ -const _ = require('lodash') -const mime = require('mime') -const path = require('path') -const Promise = require('bluebird') -const dataUriToBuffer = require('data-uri-to-buffer') -const Jimp = require('jimp') -const sizeOf = require('image-size') -const colorString = require('color-string') -const sanitize = require('sanitize-filename') -let debug = require('debug')('cypress:server:screenshot') -const plugins = require('./plugins') -const { fs } = require('./util/fs') +import _ from 'lodash' +import Debug from 'debug' +import mime from 'mime' +import path from 'path' +import Promise from 'bluebird' +import dataUriToBuffer from 'data-uri-to-buffer' +import Jimp from 'jimp' +import sizeOf from 'image-size' +import colorString from 'color-string' +import sanitize from 'sanitize-filename' +import * as plugins from './plugins' +import { fs } from './util/fs' +let debug = Debug('cypress:server:screenshot') const RUNNABLE_SEPARATOR = ' -- ' const pathSeparatorRe = /[\\\/]/g // internal id incrementor -let __ID__ = null +let __ID__: string | null = null + +type ScreenshotsFolder = string | false | undefined + +interface Clip { + x: number + y: number + width: number + height: number +} + +// TODO: This is likely not representative of the entire Type and should be updated +interface Data { + specName: string + name: string + startTime: Date + viewport: { + width: number + height: number + } + titles?: string[] + testFailure?: boolean + overwrite?: boolean + simple?: boolean + current?: number + total?: number + testAttemptIndex?: number + appOnly?: boolean + hideRunnerUi?: boolean + clip?: Clip + userClip?: Clip +} + +// TODO: This is likely not representative of the entire Type and should be updated +interface Details { + image: any + pixelRatio: any + multipart: any + takenAt: Date +} + +// TODO: This is likely not representative of the entire Type and should be updated +interface SavedDetails { + size?: string + takenAt?: Date + dimensions?: string + multipart?: any + pixelRatio?: number + name?: any + specName?: string + testFailure?: boolean + path?: string +} // many filesystems limit filename length to 255 bytes/characters, so truncate the filename to // the smallest common denominator of safe filenames, which is 255 bytes. when ENAMETOOLONG @@ -34,18 +87,32 @@ const MIN_PREFIX_BYTES = 64 // screenshot id to the debug logs for easier association debug = _.wrap(debug, (fn, str, ...args) => { return fn(`(${__ID__}) ${str}`, ...args) -}) +}) as Debug.Debugger -const isBlack = (rgba) => { +interface RGBA { + r: number + g: number + b: number + a: number +} + +const isBlack = (rgba: RGBA): boolean => { return `${rgba.r}${rgba.g}${rgba.b}` === '000' } -const isWhite = (rgba) => { +const isWhite = (rgba: RGBA): boolean => { return `${rgba.r}${rgba.g}${rgba.b}` === '255255255' } -const intToRGBA = function (int) { - const obj = Jimp.intToRGBA(int) +interface RGBAWithName extends RGBA { + name?: string + isNotWhite?: boolean + isWhite?: boolean + isBlack?: boolean +} + +const intToRGBA = function (int: number): RGBAWithName { + const obj: RGBAWithName = Jimp.intToRGBA(int) as RGBAWithName if (debug.enabled) { obj.name = colorString.to.keyword([ @@ -108,14 +175,14 @@ const hasHelperPixels = function (image, pixelRatio) { ) } -const captureAndCheck = function (data, automate, conditionFn) { +const captureAndCheck = function (data: Data, automate, conditionFn) { let attempt const start = new Date() let tries = 0 return (attempt = function () { tries++ - const totalDuration = new Date() - start + const totalDuration = new Date().getTime() - start.getTime() debug('capture and check %o', { tries, totalDuration }) @@ -140,7 +207,7 @@ const captureAndCheck = function (data, automate, conditionFn) { })() } -const isMultipart = (data) => { +const isMultipart = (data: Data) => { return _.isNumber(data.current) && _.isNumber(data.total) } @@ -166,7 +233,7 @@ const crop = function (image, dimensions, pixelRatio = 1) { return image.clone().crop(x, y, width, height) } -const pixelConditionFn = function (data, image) { +const pixelConditionFn = function (data: Data, image) { const pixelRatio = image.bitmap.width / data.viewport.width const hasPixels = hasHelperPixels(image, pixelRatio) @@ -187,7 +254,7 @@ const pixelConditionFn = function (data, image) { return passes } -let multipartImages = [] +let multipartImages: { data: Data, image, takenAt, __ID__ }[] = [] const clearMultipartState = function () { debug('clearing %d cached multipart images', multipartImages.length) @@ -199,7 +266,7 @@ const imagesMatch = (img1, img2) => { return img1.bitmap.data.equals(img2.bitmap.data) } -const lastImagesAreDifferent = function (data, image) { +const lastImagesAreDifferent = function (data: Data, image) { // ensure the previous image isn't the same, // which might indicate the page has not scrolled yet const previous = _.last(multipartImages) @@ -222,7 +289,7 @@ const lastImagesAreDifferent = function (data, image) { return !matches } -const multipartConditionFn = function (data, image) { +const multipartConditionFn = function (data: Data, image) { if (data.current === 1) { return pixelConditionFn(data, image) && lastImagesAreDifferent(data, image) } @@ -246,7 +313,7 @@ const stitchScreenshots = function (pixelRatio) { debug(`stitch ${multipartImages.length} images together`) - const takenAts = [] + const takenAts: string[] = [] let heightMarker = 0 const fullImage = new Jimp(fullWidth, fullHeight) @@ -278,6 +345,7 @@ const getBuffer = function (details) { return Promise .promisify(details.image.getBuffer) + // @ts-expect-error .call(details.image, Jimp.AUTO) } @@ -293,7 +361,7 @@ const getDimensions = function (details) { return pick(details.image.bitmap) } -const ensureSafePath = function (withoutExt, extension, overwrite, num = 0) { +const ensureSafePath = function (withoutExt: string, extension: string, overwrite: Data['overwrite'], num = 0) { const suffix = `${(num && !overwrite) ? ` (${num})` : ''}.${extension}` const maxSafePrefixBytes = maxSafeBytes - suffix.length @@ -316,6 +384,7 @@ const ensureSafePath = function (withoutExt, extension, overwrite, num = 0) { } // path does not exist, attempt to create it to check for an ENAMETOOLONG error + // @ts-expect-error return fs.outputFileAsync(fullPath, '') .then(() => fullPath) .catch((err) => { @@ -332,24 +401,26 @@ const ensureSafePath = function (withoutExt, extension, overwrite, num = 0) { }) } -const sanitizeToString = (title) => { +const sanitizeToString = (title: string | null | undefined) => { // test titles may be values which aren't strings like // null or undefined - so convert before trying to sanitize return sanitize(_.toString(title)) } -const getPath = function (data, ext, screenshotsFolder, overwrite) { +const getPath = function (data: Data, ext, screenshotsFolder: ScreenshotsFolder, overwrite: Data['overwrite']) { let names const specNames = (data.specName || '') .split(pathSeparatorRe) if (data.name) { + // @ts-expect-error names = data.name.split(pathSeparatorRe).map(sanitize) } else { names = _ .chain(data.titles) .map(sanitizeToString) .join(RUNNABLE_SEPARATOR) + // @ts-expect-error - this shouldn't be necessary, but it breaks if you remove it .concat([]) .value() } @@ -361,22 +432,28 @@ const getPath = function (data, ext, screenshotsFolder, overwrite) { names[index] = `${names[index]} (failed)` } - if (data.testAttemptIndex > 0) { + if (data.testAttemptIndex && data.testAttemptIndex > 0) { names[index] = `${names[index]} (attempt ${data.testAttemptIndex + 1})` } - const withoutExt = path.join(screenshotsFolder, ...specNames, ...names) + let withoutExt + + if (screenshotsFolder) { + withoutExt = path.join(screenshotsFolder, ...specNames, ...names) + } else { + withoutExt = path.join(...specNames, ...names) + } return ensureSafePath(withoutExt, ext, overwrite) } -const getPathToScreenshot = function (data, details, screenshotsFolder) { +const getPathToScreenshot = function (data: Data, details: Details, screenshotsFolder: ScreenshotsFolder) { const ext = mime.getExtension(getType(details)) return getPath(data, ext, screenshotsFolder, data.overwrite) } -module.exports = { +export = { crop, getPath, @@ -385,7 +462,7 @@ module.exports = { imagesMatch, - capture (data, automate) { + capture (data: Data, automate) { __ID__ = _.uniqueId('s') debug('capturing screenshot %o', data) @@ -419,7 +496,7 @@ module.exports = { debug(`multi-part ${data.current}/${data.total}`) } - if (multipart && (data.total > 1)) { + if (multipart && (data.total && data.total > 1)) { // keep previous screenshot partials around b/c if two screenshots are // taken in a row, the UI might not be caught up so we need something // to compare the new one to @@ -461,15 +538,16 @@ module.exports = { }) }, - save (data, details, screenshotsFolder) { + save (data: Data, details: Details, screenshotsFolder: ScreenshotsFolder) { return getPathToScreenshot(data, details, screenshotsFolder) .then((pathToScreenshot) => { debug('save', pathToScreenshot) return getBuffer(details) .then((buffer) => { - return fs.outputFileAsync(pathToScreenshot, buffer) + return fs.outputFile(pathToScreenshot, buffer) }).then(() => { + // @ts-expect-error TODO: size is not assignable here return fs.statAsync(pathToScreenshot).get('size') }).then((size) => { const dimensions = getDimensions(details) @@ -491,8 +569,8 @@ module.exports = { }) }, - afterScreenshot (data, details) { - const duration = new Date() - new Date(data.startTime) + afterScreenshot (data: Data, details: SavedDetails) { + const duration = new Date().getTime() - new Date(data.startTime).getTime() details = _.extend({}, data, details, { duration }) details = _.pick(details, 'testAttemptIndex', 'size', 'takenAt', 'dimensions', 'multipart', 'pixelRatio', 'name', 'specName', 'testFailure', 'path', 'scaled', 'blackout', 'duration') diff --git a/packages/server/lib/util/chromium_flags.ts b/packages/server/lib/util/chromium_flags.ts index eb45e6230f..f803725f86 100644 --- a/packages/server/lib/util/chromium_flags.ts +++ b/packages/server/lib/util/chromium_flags.ts @@ -36,7 +36,7 @@ const DEFAULT_FLAGS = [ 'enable-automation', 'disable-print-preview', 'disable-component-extensions-with-background-pages', - + 'disable-infobars', 'disable-device-discovery-notifications', // https://github.com/cypress-io/cypress/issues/2376 diff --git a/packages/server/tsconfig.json b/packages/server/tsconfig.json index 5a24150420..9c69ae92c3 100644 --- a/packages/server/tsconfig.json +++ b/packages/server/tsconfig.json @@ -9,12 +9,5 @@ ], "compilerOptions": { "lib": ["esnext"], - "types": [ - "mocha", - "node" - ], - "resolveJsonModule": true, - "noUnusedLocals": false, - "importHelpers": true } } diff --git a/packages/socket/tsconfig.json b/packages/socket/tsconfig.json index 9b7d0907d5..94523723d3 100644 --- a/packages/socket/tsconfig.json +++ b/packages/socket/tsconfig.json @@ -1,7 +1,6 @@ { "extends": "./../ts/tsconfig.json", "compilerOptions": { - "strict": true, "noImplicitAny": true, "skipLibCheck": false }, diff --git a/packages/telemetry/tsconfig.json b/packages/telemetry/tsconfig.json index edd15e17bb..d887c0486c 100644 --- a/packages/telemetry/tsconfig.json +++ b/packages/telemetry/tsconfig.json @@ -4,13 +4,8 @@ "compilerOptions": { "outDir": "./dist", "lib": ["esnext", "DOM"], - "strict": true, "allowJs": false, "noImplicitAny": true, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUnusedLocals": false, - "noUncheckedIndexedAccess": true, "types": ["cypress"], } } diff --git a/packages/ts/README.md b/packages/ts/README.md index dcf27567d4..4c46ce9e23 100644 --- a/packages/ts/README.md +++ b/packages/ts/README.md @@ -1,6 +1,6 @@ # TS -Internal package used to standardize this repo's version of `ts-node` used for development. In production we pre-transpile all of the typescript so this packages `register` export is a no-op +Internal package used to standardize this repo's version of `ts-node` and the base `tsconfig` options used for development. In production we pre-transpile all of the typescript so this packages `register` export is a no-op ## Installing N/A - handled by the top level `yarn install` diff --git a/packages/ts/tsconfig.json b/packages/ts/tsconfig.json index 0f0e239b75..20f39e2b45 100644 --- a/packages/ts/tsconfig.json +++ b/packages/ts/tsconfig.json @@ -1,65 +1,118 @@ { "compilerOptions": { - /* Basic Options */ - "target": "ES2018", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', or 'ESNEXT'. */ - "module": "commonjs", /* Specify module code generation: 'commonjs', 'amd', 'system', 'umd' or 'es2015'. */ - "lib": ["es2021"], /* Specify library files to be included in the compilation: */ - // "allowJs": true, /* Allow javascript files to be compiled. */ - // "checkJs": true, /* Report errors in .js files. */ - "jsx": "react", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */ - "skipLibCheck": true, - // "declaration": true, /* Generates corresponding '.d.ts' file. */ - // "sourceMap": true, /* Generates corresponding '.map' file. */ - // "outFile": "./", /* Concatenate and emit output to single file. */ - // "outDir": "./", /* Redirect output structure to the directory. */ - // "rootDir": "./", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */ - // "removeComments": true, /* Do not emit comments to output. */ - // "noEmit": true, /* Do not emit outputs. */ - "importHelpers": true, /* Import emit helpers from 'tslib'. */ - // "downlevelIteration": true, /* Provide full support for iterables in 'for-of', spread, and destructuring when targeting 'ES5' or 'ES3'. */ - // "isolatedModules": true, /* Transpile each file as a separate module (similar to 'ts.transpileModule'). */ - "useUnknownInCatchVariables": false, + /* Visit https://aka.ms/tsconfig to read more about this file */ - /* Strict Type-Checking Options */ - "strict": true, /* Enable all strict type-checking options. */ - "noImplicitAny": false, /* Raise error on expressions and declarations with an implied 'any' type. */ - // "strictNullChecks": true, /* Enable strict null checks. */ - // "noImplicitThis": true, /* Raise error on 'this' expressions with an implied 'any' type. */ - // "alwaysStrict": true, /* Parse in strict mode and emit "use strict" for each source file. */ + /* Projects */ + // "incremental": true, /* Save .tsbuildinfo files to allow for incremental compilation of projects. */ + // "composite": true, /* Enable constraints that allow a TypeScript project to be used with project references. */ + // "tsBuildInfoFile": "./.tsbuildinfo", /* Specify the path to .tsbuildinfo incremental compilation file. */ + // "disableSourceOfProjectReferenceRedirect": true, /* Disable preferring source files instead of declaration files when referencing composite projects. */ + // "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */ + // "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */ - /* Additional Checks */ - - // noUnusedLocals should be linted, not type-check'ed - "noUnusedLocals": false, /* Report errors on unused locals. */ - "noUnusedParameters": false, /* Report errors on unused parameters. */ - "noImplicitReturns": true, /* Report error when not all code paths in function return a value. */ - "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */ + /* Language and Environment */ + "target": "ES2018", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */ + "lib": ["es2021"], /* Specify a set of bundled library declaration files that describe the target runtime environment. */ + "jsx": "react", /* Specify what JSX code is generated. */ + "experimentalDecorators": true, /* Enable experimental support for legacy experimental decorators. */ + // "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */ + // "jsxFactory": "", /* Specify the JSX factory function used when targeting React JSX emit, e.g. 'React.createElement' or 'h'. */ + // "jsxFragmentFactory": "", /* Specify the JSX Fragment reference used for fragments when targeting React JSX emit e.g. 'React.Fragment' or 'Fragment'. */ + // "jsxImportSource": "", /* Specify module specifier used to import the JSX factory functions when using 'jsx: react-jsx*'. */ + // "reactNamespace": "", /* Specify the object invoked for 'createElement'. This only applies when targeting 'react' JSX emit. */ + // "noLib": true, /* Disable including any library files, including the default lib.d.ts. */ + // "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */ + // "moduleDetection": "auto", /* Control what method is used to detect module-format JS files. */ - /* Module Resolution Options */ - "moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */ - // "baseUrl": "./", /* Base directory to resolve non-absolute module names. */ - // "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */ - // "rootDirs": [], /* List of root folders whose combined content represents the structure of the project at runtime. */ - //"typeRoots": [], /* List of folders to include type definitions from. */ - "types": ["mocha", "node"], /* Type declaration files to be included in compilation. */ - "allowSyntheticDefaultImports": true, /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */ - "esModuleInterop": true, + /* Modules */ + "module": "commonjs", /* Specify what module code is generated. */ + // "rootDir": "./", /* Specify the root folder within your source files. */ + "moduleResolution": "node", /* Specify how TypeScript looks up a file from a given module specifier. */ + // "baseUrl": "./", /* Specify the base directory to resolve non-relative module names. */ + // "paths": {}, /* Specify a set of entries that re-map imports to additional lookup locations. */ + // "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */ + // "typeRoots": [], /* Specify multiple folders that act like './node_modules/@types'. */ + "types": ["mocha", "node"], /* Specify type package names to be included without being referenced in a source file. */ + // "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */ + // "moduleSuffixes": [], /* List of file name suffixes to search when resolving a module. */ + // "allowImportingTsExtensions": true, /* Allow imports to include TypeScript file extensions. Requires '--moduleResolution bundler' and either '--noEmit' or '--emitDeclarationOnly' to be set. */ + // "resolvePackageJsonExports": true, /* Use the package.json 'exports' field when resolving package imports. */ + // "resolvePackageJsonImports": true, /* Use the package.json 'imports' field when resolving imports. */ + // "customConditions": [], /* Conditions to set in addition to the resolver-specific defaults when resolving imports. */ + "resolveJsonModule": true, /* Enable importing .json files. */ + // "allowArbitraryExtensions": true, /* Enable importing files with any extension, provided a declaration file is present. */ + // "noResolve": true, /* Disallow 'import's, 'require's or ''s from expanding the number of files TypeScript should add to a project. */ - /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ - // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ - // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ + /* JavaScript Support */ + // "allowJs": true, /* Allow JavaScript files to be a part of your program. Use the 'checkJS' option to get errors from these files. */ + // "checkJs": true, /* Enable error reporting in type-checked JavaScript files. */ + // "maxNodeModuleJsDepth": 1, /* Specify the maximum folder depth used for checking JavaScript files from 'node_modules'. Only applicable with 'allowJs'. */ - /* Experimental Options */ - "experimentalDecorators": true, /* Enables experimental support for ES7 decorators. */ - // "emitDecoratorMetadata": true, /* Enables experimental support for emitting type metadata for decorators. */ - "ignoreDeprecations": "5.0", + /* Emit */ + // "declaration": true, /* Generate .d.ts files from TypeScript and JavaScript files in your project. */ + // "declarationMap": true, /* Create sourcemaps for d.ts files. */ + // "emitDeclarationOnly": true, /* Only output d.ts files and not JavaScript files. */ + // "sourceMap": true, /* Create source map files for emitted JavaScript files. */ + // "inlineSourceMap": true, /* Include sourcemap files inside the emitted JavaScript. */ + // "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If 'declaration' is true, also designates a file that bundles all .d.ts output. */ + // "outDir": "./", /* Specify an output folder for all emitted files. */ + // "removeComments": true, /* Disable emitting comments. */ + // "noEmit": true, /* Disable emitting files from a compilation. */ + "importHelpers": true, /* Allow importing helper functions from tslib once per project, instead of including them per-file. */ /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", - "resolveJsonModule": true + * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior + * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. + */ + "importsNotUsedAsValues": "error", /* Specify emit/checking behavior for imports that are only used for types. */ + // "downlevelIteration": true, /* Emit more compliant, but verbose and less performant JavaScript for iteration. */ + // "sourceRoot": "", /* Specify the root path for debuggers to find the reference source code. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "inlineSources": true, /* Include source code in the sourcemaps inside the emitted JavaScript. */ + // "emitBOM": true, /* Emit a UTF-8 Byte Order Mark (BOM) in the beginning of output files. */ + // "newLine": "crlf", /* Set the newline character for emitting files. */ + // "stripInternal": true, /* Disable emitting declarations that have '@internal' in their JSDoc comments. */ + // "noEmitHelpers": true, /* Disable generating custom helper functions like '__extends' in compiled output. */ + // "noEmitOnError": true, /* Disable emitting files if any type checking errors are reported. */ + // "preserveConstEnums": true, /* Disable erasing 'const enum' declarations in generated code. */ + // "declarationDir": "./", /* Specify the output directory for generated declaration files. */ + // "preserveValueImports": true, /* Preserve unused imported values in the JavaScript output that would otherwise be removed. */ + + /* Interop Constraints */ + // "isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */ + // "verbatimModuleSyntax": true, /* Do not transform or elide any imports or exports not marked as type-only, ensuring they are written in the output file's format based on the 'module' setting. */ + "allowSyntheticDefaultImports": true, /* Allow 'import x from y' when a module doesn't have a default export. */ + "esModuleInterop": true, /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables 'allowSyntheticDefaultImports' for type compatibility. */ + // "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */ + "forceConsistentCasingInFileNames": true, /* Ensure that casing is correct in imports. */ + + /* Type Checking */ + "strict": true, /* Enable all strict type-checking options. */ + "noImplicitAny": false, /* Enable error reporting for expressions and declarations with an implied 'any' type. */ + // "strictNullChecks": true, /* When type checking, take into account 'null' and 'undefined'. */ + // "strictFunctionTypes": true, /* When assigning functions, check to ensure parameters and the return values are subtype-compatible. */ + // "strictBindCallApply": true, /* Check that the arguments for 'bind', 'call', and 'apply' methods match the original function. */ + // "strictPropertyInitialization": true, /* Check for class properties that are declared but not set in the constructor. */ + // "noImplicitThis": true, /* Enable error reporting when 'this' is given the type 'any'. */ + "useUnknownInCatchVariables": false, /* Default catch clause variables as 'unknown' instead of 'any'. */ + // "alwaysStrict": true, /* Ensure 'use strict' is always emitted. */ + "noUnusedLocals": false, /* Enable error reporting when local variables aren't read. */ + "noUnusedParameters": false, /* Raise an error when a function parameter isn't read. */ + // "exactOptionalPropertyTypes": true, /* Interpret optional property types as written, rather than adding 'undefined'. */ + // "noImplicitReturns": true, /* Enable error reporting for codepaths that do not explicitly return in a function. */ + // "noFallthroughCasesInSwitch": true, /* Enable error reporting for fallthrough cases in switch statements. */ + // "noUncheckedIndexedAccess": true, /* Add 'undefined' to a type when accessed using an index. */ + // "noImplicitOverride": true, /* Ensure overriding members in derived classes are marked with an override modifier. */ + // "noPropertyAccessFromIndexSignature": true, /* Enforces using indexed accessors for keys declared using an indexed type. */ + // "allowUnusedLabels": true, /* Disable error reporting for unused labels. */ + // "allowUnreachableCode": true, /* Disable error reporting for unreachable code. */ + + /* Completeness */ + // "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */ + "skipLibCheck": true, /* Skip type checking all .d.ts files. */ + + /* + * TODO: remove ignoreDeprecations after typescript 5.5. This is used to assist in the transition to typescript 5.5 and up. + */ + "ignoreDeprecations": "5.0", } } diff --git a/system-tests/__snapshots__/component_testing_spec.ts.js b/system-tests/__snapshots__/component_testing_spec.ts.js index b9341d4628..2f70177230 100644 --- a/system-tests/__snapshots__/component_testing_spec.ts.js +++ b/system-tests/__snapshots__/component_testing_spec.ts.js @@ -364,9 +364,9 @@ exports['experimentalSingleTabRunMode / executes all specs in a single tab'] = ` (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/1_fails.cy.js/simple failing spec -- fails (fai (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/1_fails.cy.js/simple failing spec -- fails (fai (1280x633) led).png - - /XXX/XXX/XXX/cypress/screenshots/1_fails.cy.js/simple failing spec -- fails agai (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/1_fails.cy.js/simple failing spec -- fails agai (1280x633) n (failed).png diff --git a/system-tests/__snapshots__/plugins_spec.js b/system-tests/__snapshots__/plugins_spec.js index 4cd267e25f..afc98d06d7 100644 --- a/system-tests/__snapshots__/plugins_spec.js +++ b/system-tests/__snapshots__/plugins_spec.js @@ -7,7 +7,7 @@ Cypress supports the following browsers: - electron - chrome - chromium - - chrome:canary + - chrome-for-testing - edge - firefox diff --git a/system-tests/__snapshots__/record_spec.js b/system-tests/__snapshots__/record_spec.js index d837ef612f..beb05d75a3 100644 --- a/system-tests/__snapshots__/record_spec.js +++ b/system-tests/__snapshots__/record_spec.js @@ -556,7 +556,7 @@ Cypress supports the following browsers: - electron - chrome - chromium - - chrome:canary + - chrome-for-testing - edge - firefox diff --git a/system-tests/__snapshots__/retries_spec.ts.js b/system-tests/__snapshots__/retries_spec.ts.js index d88ae5dc7b..9e99c236d0 100644 --- a/system-tests/__snapshots__/retries_spec.ts.js +++ b/system-tests/__snapshots__/retries_spec.ts.js @@ -164,8 +164,8 @@ exports['retries / supports retries (chrome)'] = ` (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/fail-twice.cy.js/fail twice (failed).png (1280x581) - - /XXX/XXX/XXX/cypress/screenshots/fail-twice.cy.js/fail twice (failed) (attempt 2 (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/fail-twice.cy.js/fail twice (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/fail-twice.cy.js/fail twice (failed) (attempt 2 (1280x633) ).png diff --git a/system-tests/__snapshots__/vite_dev_server_fresh_spec.ts.js b/system-tests/__snapshots__/vite_dev_server_fresh_spec.ts.js index 778ea35ff7..cb35b17944 100644 --- a/system-tests/__snapshots__/vite_dev_server_fresh_spec.ts.js +++ b/system-tests/__snapshots__/vite_dev_server_fresh_spec.ts.js @@ -82,7 +82,7 @@ We dynamically generated a new test to display this failure. (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x633) s detected outside of a test (failed).png @@ -165,12 +165,12 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x633) .png - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x581) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x633) g - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x633) ).png @@ -216,7 +216,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x633) ng @@ -254,7 +254,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x633) his file (failed).png @@ -410,8 +410,745 @@ exports['@cypress/vite-dev-server / react / executes all of the tests for vite4. ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ │ Cypress: 1.2.3 │ │ Browser: FooBrowser 88 │ - │ Specs: 1 found (port.cy.jsx) │ - │ Searched: src/port.cy.jsx │ + │ Specs: 9 found (App.cy.jsx, AppCompilationError.cy.jsx, Errors.cy.jsx, MissingReact.cy.js │ + │ x, MissingReactInSpec.cy.jsx, Rerendering.cy.jsx, Unmount.cy.jsx, mount.cy.jsx, po │ + │ rt.cy.jsx) │ + │ Searched: **/*.cy.{js,jsx,ts,tsx} │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: App.cy.jsx (1 of 9) + + + ✓ renders hello world + ✓ renders background + + 2 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 2 │ + │ Passing: 2 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: App.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: AppCompilationError.cy.jsx (2 of 9) + + + 1) An uncaught error was detected outside of a test + + 0 passing + 1 failing + + 1) An uncaught error was detected outside of a test: + TypeError: The following error originated from your test code, not from Cypress. + + > Failed to fetch dynamically imported module: http://localhost:8888/__cypress/src/@fs/foo/bar/.projects/vite2.8.6-react/src/AppCompilationError.cy.jsx + +When Cypress detects uncaught errors originating from your test code it will automatically fail the current test. + +Cypress could not associate this error to any specific test. + +We dynamically generated a new test to display this failure. + + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: AppCompilationError.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x633) + s detected outside of a test (failed).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Errors.cy.jsx (3 of 9) + + + Errors + 1) error on mount + 2) sync error + 3) async error + 4) command failure + + + 0 passing + 4 failing + + 1) Errors + error on mount: + Error: The following error originated from your application code, not from Cypress. + + > mount error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 2) Errors + sync error: + Error: The following error originated from your application code, not from Cypress. + + > sync error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 3) Errors + async error: + Error: The following error originated from your application code, not from Cypress. + + > async error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 4) Errors + command failure: + AssertionError: Timed out retrying after 50ms: Expected to find element: \`element-that-does-not-exist\`, but never found it. + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 4 │ + │ Passing: 0 │ + │ Failing: 4 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 4 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Errors.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x633) + .png + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x633) + g + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x633) + ).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: MissingReact.cy.jsx (4 of 9) + + + 1) is missing React + + 0 passing + 1 failing + + 1) is missing React: + ReferenceError: The following error originated from your application code, not from Cypress. + + > React is not defined + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: MissingReact.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x633) + ng + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: MissingReactInSpec.cy.jsx (5 of 9) + + + 1) is missing React in this file + + 0 passing + 1 failing + + 1) is missing React in this file: + ReferenceError: React is not defined + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: MissingReactInSpec.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x633) + his file (failed).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Rerendering.cy.jsx (6 of 9) + + + re-render + ✓ maintains component state across re-renders + + + 1 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 1 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Rerendering.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Unmount.cy.jsx (7 of 9) + + + Comp with componentWillUnmount + ✓ calls the prop + + mount cleanup + ✓ mount 1 + ✓ mount 2 + + + 3 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 3 │ + │ Passing: 3 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Unmount.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: mount.cy.jsx (8 of 9) + + + mount + ✓ does not error when rendering primitives + teardown + ✓ should mount + ✓ should remove previous mounted component + + + 3 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 3 │ + │ Passing: 3 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: mount.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: port.cy.jsx (9 of 9) + + + ✓ ensures we have launched at the overridden port + + 1 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 1 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: port.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +==================================================================================================== + + (Run Finished) + + + Spec Tests Passing Failing Pending Skipped + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ ✔ App.cy.jsx XX:XX 2 2 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ AppCompilationError.cy.jsx XX:XX 1 - 1 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ Errors.cy.jsx XX:XX 4 - 4 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ MissingReact.cy.jsx XX:XX 1 - 1 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ MissingReactInSpec.cy.jsx XX:XX 1 - 1 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ Rerendering.cy.jsx XX:XX 1 1 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ Unmount.cy.jsx XX:XX 3 3 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ mount.cy.jsx XX:XX 3 3 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ port.cy.jsx XX:XX 1 1 - - - │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + ✖ 4 of 9 failed (44%) XX:XX 17 10 7 - - + + +` + +exports['@cypress/vite-dev-server react executes all of the tests for vite2.9.1-react 1'] = ` + +==================================================================================================== + + (Run Starting) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Cypress: 1.2.3 │ + │ Browser: FooBrowser 88 │ + │ Specs: 9 found (App.cy.jsx, AppCompilationError.cy.jsx, Errors.cy.jsx, MissingReact.cy.js │ + │ x, MissingReactInSpec.cy.jsx, Rerendering.cy.jsx, Unmount.cy.jsx, mount.cy.jsx, po │ + │ rt.cy.jsx) │ + │ Searched: **/*.cy.{js,jsx,ts,tsx} │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: App.cy.jsx (1 of 9) + + + ✓ renders hello world + ✓ renders background + + 2 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 2 │ + │ Passing: 2 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: App.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: AppCompilationError.cy.jsx (2 of 9) + + + 1) An uncaught error was detected outside of a test + + 0 passing + 1 failing + + 1) An uncaught error was detected outside of a test: + TypeError: The following error originated from your test code, not from Cypress. + + > Failed to fetch dynamically imported module: http://localhost:8888/__cypress/src/@fs/foo/bar/.projects/vite2.9.1-react/src/AppCompilationError.cy.jsx + +When Cypress detects uncaught errors originating from your test code it will automatically fail the current test. + +Cypress could not associate this error to any specific test. + +We dynamically generated a new test to display this failure. + + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: AppCompilationError.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x633) + s detected outside of a test (failed).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Errors.cy.jsx (3 of 9) + + + Errors + 1) error on mount + 2) sync error + 3) async error + 4) command failure + + + 0 passing + 4 failing + + 1) Errors + error on mount: + Error: The following error originated from your application code, not from Cypress. + + > mount error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 2) Errors + sync error: + Error: The following error originated from your application code, not from Cypress. + + > sync error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 3) Errors + async error: + Error: The following error originated from your application code, not from Cypress. + + > async error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 4) Errors + command failure: + AssertionError: Timed out retrying after 50ms: Expected to find element: \`element-that-does-not-exist\`, but never found it. + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 4 │ + │ Passing: 0 │ + │ Failing: 4 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 4 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Errors.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x633) + .png + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x633) + g + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x633) + ).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: MissingReact.cy.jsx (4 of 9) + + + 1) is missing React + + 0 passing + 1 failing + + 1) is missing React: + ReferenceError: The following error originated from your application code, not from Cypress. + + > React is not defined + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: MissingReact.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x633) + ng + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: MissingReactInSpec.cy.jsx (5 of 9) + + + 1) is missing React in this file + + 0 passing + 1 failing + + 1) is missing React in this file: + ReferenceError: React is not defined + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: MissingReactInSpec.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x633) + his file (failed).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Rerendering.cy.jsx (6 of 9) + + + re-render + ✓ maintains component state across re-renders + + + 1 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 1 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Rerendering.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Unmount.cy.jsx (7 of 9) + + + Comp with componentWillUnmount + ✓ calls the prop + + mount cleanup + ✓ mount 1 + ✓ mount 2 + + + 3 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 3 │ + │ Passing: 3 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Unmount.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: mount.cy.jsx (8 of 9) + + + mount + ✓ does not error when rendering primitives + teardown + ✓ should mount + ✓ should remove previous mounted component + + + 3 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 3 │ + │ Passing: 3 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: mount.cy.jsx │ └────────────────────────────────────────────────────────────────────────────────────────────────┘ @@ -538,7 +1275,7 @@ We dynamically generated a new test to display this failure. (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x633) s detected outside of a test (failed).png @@ -621,12 +1358,12 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x633) .png - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x581) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x633) g - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x633) ).png @@ -672,7 +1409,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x633) ng @@ -710,7 +1447,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x633) his file (failed).png @@ -994,7 +1731,7 @@ We dynamically generated a new test to display this failure. (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x633) s detected outside of a test (failed).png @@ -1077,12 +1814,12 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x633) .png - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x581) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x633) g - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x633) ).png @@ -1128,7 +1865,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x633) ng @@ -1166,7 +1903,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x633) his file (failed).png diff --git a/system-tests/__snapshots__/webpack_dev_server_fresh_spec.ts.js b/system-tests/__snapshots__/webpack_dev_server_fresh_spec.ts.js index 6e8cd889fd..2a977d6c48 100644 --- a/system-tests/__snapshots__/webpack_dev_server_fresh_spec.ts.js +++ b/system-tests/__snapshots__/webpack_dev_server_fresh_spec.ts.js @@ -224,7 +224,7 @@ We dynamically generated a new test to display this failure. (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x633) s detected outside of a test (failed).png @@ -307,12 +307,12 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x633) .png - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x581) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x633) g - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x633) ).png @@ -358,7 +358,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x633) ng @@ -396,7 +396,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x633) his file (failed).png @@ -664,7 +664,7 @@ We dynamically generated a new test to display this failure. (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x633) s detected outside of a test (failed).png @@ -747,12 +747,12 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x633) .png - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x581) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x633) g - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x633) ).png @@ -798,7 +798,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x633) ng @@ -836,7 +836,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x633) his file (failed).png @@ -1039,49 +1039,11 @@ SyntaxError: /foo/bar/.projects/webpack5_wds5-react/src/AppCompilationError.cy.j 9 | [stack trace lines] -webpack compiled with 1 error - - - 1) An uncaught error was detected outside of a test - - 0 passing - 1 failing - - 1) An uncaught error was detected outside of a test: - The following error originated from your test code, not from Cypress. - - > Module build failed (from [..]): -SyntaxError: /foo/bar/.projects/webpack5_wds5-react/src/AppCompilationError.cy.jsx: Unexpected token, expected "," (8:0) - - 6 | cy.get('h1').contains('Hello World') - 7 | } -> 8 | }) - | ^ - 9 | - [stack trace lines] - When Cypress detects uncaught errors originating from your test code it will automatically fail the current test. Cypress could not associate this error to any specific test. We dynamically generated a new test to display this failure. - Error: The following error originated from your test code, not from Cypress. - - > Module build failed (from [..]): - SyntaxError: /foo/bar/.projects/webpack5_wds5-react/src/AppCompilationError.cy.jsx: Unexpected token, expected "," (8:0) - - 6 | cy.get('h1').contains('Hello World') - 7 | } - > 8 | }) - | ^ - 9 | - [stack trace lines] - - When Cypress detects uncaught errors originating from your test code it will automatically fail the current test. - - Cypress could not associate this error to any specific test. - - We dynamically generated a new test to display this failure. [stack trace lines] @@ -1104,7 +1066,7 @@ We dynamically generated a new test to display this failure. (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x633) s detected outside of a test (failed).png @@ -1187,12 +1149,12 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x633) .png - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x581) - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x633) g - - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x633) ).png @@ -1238,7 +1200,7 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x633) ng @@ -1276,7 +1238,876 @@ https://on.cypress.io/uncaught-exception-from-application (Screenshots) - - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x581) + - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x633) + his file (failed).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Rerendering.cy.jsx (6 of 9) + + + re-render + ✓ maintains component state across re-renders + + + 1 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 1 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Rerendering.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Unmount.cy.jsx (7 of 9) + + + Comp with componentWillUnmount + ✓ calls the prop + + mount cleanup + ✓ mount 1 + ✓ mount 2 + + + 3 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 3 │ + │ Passing: 3 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Unmount.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: mount.cy.jsx (8 of 9) + + + mount + ✓ does not error when rendering primitives + teardown + ✓ should mount + ✓ should remove previous mounted component + + + 3 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 3 │ + │ Passing: 3 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: mount.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: port.cy.jsx (9 of 9) + + + ✓ ensures we have launched at the overridden port + + 1 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 1 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: port.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +==================================================================================================== + + (Run Finished) + + + Spec Tests Passing Failing Pending Skipped + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ ✔ App.cy.jsx XX:XX 2 2 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ AppCompilationError.cy.jsx XX:XX 1 - 1 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ Errors.cy.jsx XX:XX 4 - 4 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ MissingReact.cy.jsx XX:XX 1 - 1 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ MissingReactInSpec.cy.jsx XX:XX 1 - 1 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ Rerendering.cy.jsx XX:XX 1 1 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ Unmount.cy.jsx XX:XX 3 3 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ mount.cy.jsx XX:XX 3 3 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ port.cy.jsx XX:XX 1 1 - - - │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + ✖ 4 of 9 failed (44%) XX:XX 17 10 7 - - + + +` + +exports['@cypress/webpack-dev-server / react / executes all of the tests for webpack5_wds4-react'] = ` + +==================================================================================================== + + (Run Starting) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Cypress: 1.2.3 │ + │ Browser: FooBrowser 88 │ + │ Specs: 9 found (App.cy.jsx, AppCompilationError.cy.jsx, Errors.cy.jsx, MissingReact.cy.js │ + │ x, MissingReactInSpec.cy.jsx, Rerendering.cy.jsx, Unmount.cy.jsx, mount.cy.jsx, po │ + │ rt.cy.jsx) │ + │ Searched: **/*.cy.{js,jsx,ts,tsx} │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: App.cy.jsx (1 of 9) +16 assets +68 modules + +ERROR in ./src/AppCompilationError.cy.jsx +Module build failed (from [..]): +SyntaxError: /foo/bar/.projects/webpack5_wds4-react/src/AppCompilationError.cy.jsx: Unexpected token, expected "," (8:0) + + 6 | cy.get('h1').contains('Hello World') + 7 | } +> 8 | }) + | ^ + 9 | + [stack trace lines] + +webpack x.x.x compiled with x errors in xxx ms + + + ✓ renders hello world + ✓ renders background + + 2 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 2 │ + │ Passing: 2 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: App.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: AppCompilationError.cy.jsx (2 of 9) + + + 1) An uncaught error was detected outside of a test + + 0 passing + 1 failing + + 1) An uncaught error was detected outside of a test: + Error: The following error originated from your test code, not from Cypress. + + > Module build failed (from [..]): +SyntaxError: /foo/bar/.projects/webpack5_wds4-react/src/AppCompilationError.cy.jsx: Unexpected token, expected "," (8:0) + + 6 | cy.get('h1').contains('Hello World') + 7 | } +> 8 | }) + | ^ + 9 | + [stack trace lines] + +When Cypress detects uncaught errors originating from your test code it will automatically fail the current test. + +Cypress could not associate this error to any specific test. + +We dynamically generated a new test to display this failure. + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: AppCompilationError.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x633) + s detected outside of a test (failed).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Errors.cy.jsx (3 of 9) + + + Errors + 1) error on mount + 2) sync error + 3) async error + 4) command failure + + + 0 passing + 4 failing + + 1) Errors + error on mount: + Error: The following error originated from your application code, not from Cypress. + + > mount error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 2) Errors + sync error: + Error: The following error originated from your application code, not from Cypress. + + > sync error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 3) Errors + async error: + Error: The following error originated from your application code, not from Cypress. + + > async error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 4) Errors + command failure: + AssertionError: Timed out retrying after 50ms: Expected to find element: \`element-that-does-not-exist\`, but never found it. + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 4 │ + │ Passing: 0 │ + │ Failing: 4 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 4 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Errors.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x633) + .png + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x633) + g + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x633) + ).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: MissingReact.cy.jsx (4 of 9) + + + 1) is missing React + + 0 passing + 1 failing + + 1) is missing React: + ReferenceError: The following error originated from your application code, not from Cypress. + + > React is not defined + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: MissingReact.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x633) + ng + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: MissingReactInSpec.cy.jsx (5 of 9) + + + 1) is missing React in this file + + 0 passing + 1 failing + + 1) is missing React in this file: + ReferenceError: React is not defined + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: MissingReactInSpec.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x633) + his file (failed).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Rerendering.cy.jsx (6 of 9) + + + re-render + ✓ maintains component state across re-renders + + + 1 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 1 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Rerendering.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Unmount.cy.jsx (7 of 9) + + + Comp with componentWillUnmount + ✓ calls the prop + + mount cleanup + ✓ mount 1 + ✓ mount 2 + + + 3 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 3 │ + │ Passing: 3 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Unmount.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: mount.cy.jsx (8 of 9) + + + mount + ✓ does not error when rendering primitives + teardown + ✓ should mount + ✓ should remove previous mounted component + + + 3 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 3 │ + │ Passing: 3 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: mount.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: port.cy.jsx (9 of 9) + + + ✓ ensures we have launched at the overridden port + + 1 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 1 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: port.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +==================================================================================================== + + (Run Finished) + + + Spec Tests Passing Failing Pending Skipped + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ ✔ App.cy.jsx XX:XX 2 2 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ AppCompilationError.cy.jsx XX:XX 1 - 1 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ Errors.cy.jsx XX:XX 4 - 4 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ MissingReact.cy.jsx XX:XX 1 - 1 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✖ MissingReactInSpec.cy.jsx XX:XX 1 - 1 - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ Rerendering.cy.jsx XX:XX 1 1 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ Unmount.cy.jsx XX:XX 3 3 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ mount.cy.jsx XX:XX 3 3 - - - │ + ├────────────────────────────────────────────────────────────────────────────────────────────────┤ + │ ✔ port.cy.jsx XX:XX 1 1 - - - │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + ✖ 4 of 9 failed (44%) XX:XX 17 10 7 - - + + +` + +exports['@cypress/webpack-dev-server / react / executes all of the tests for webpack5_wds5-react'] = ` + +==================================================================================================== + + (Run Starting) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Cypress: 1.2.3 │ + │ Browser: FooBrowser 88 │ + │ Specs: 9 found (App.cy.jsx, AppCompilationError.cy.jsx, Errors.cy.jsx, MissingReact.cy.js │ + │ x, MissingReactInSpec.cy.jsx, Rerendering.cy.jsx, Unmount.cy.jsx, mount.cy.jsx, po │ + │ rt.cy.jsx) │ + │ Searched: **/*.cy.{js,jsx,ts,tsx} │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: App.cy.jsx (1 of 9) +16 assets +72 modules + +ERROR in ./src/AppCompilationError.cy.jsx +Module build failed (from [..]): +SyntaxError: /foo/bar/.projects/webpack5_wds5-react/src/AppCompilationError.cy.jsx: Unexpected token, expected "," (8:0) + + 6 | cy.get('h1').contains('Hello World') + 7 | } +> 8 | }) + | ^ + 9 | + [stack trace lines] + +webpack x.x.x compiled with x errors in xxx ms + + + ✓ renders hello world + ✓ renders background + + 2 passing + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 2 │ + │ Passing: 2 │ + │ Failing: 0 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 0 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: App.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: AppCompilationError.cy.jsx (2 of 9) + + + 1) An uncaught error was detected outside of a test + + 0 passing + 1 failing + + 1) An uncaught error was detected outside of a test: + The following error originated from your test code, not from Cypress. + + > Module build failed (from [..]): +SyntaxError: /foo/bar/.projects/webpack5_wds5-react/src/AppCompilationError.cy.jsx: Unexpected token, expected "," (8:0) + + 6 | cy.get('h1').contains('Hello World') + 7 | } +> 8 | }) + | ^ + 9 | + [stack trace lines] + +When Cypress detects uncaught errors originating from your test code it will automatically fail the current test. + +Cypress could not associate this error to any specific test. + +We dynamically generated a new test to display this failure. + Error: The following error originated from your test code, not from Cypress. + + > Module build failed (from [..]): + SyntaxError: /foo/bar/.projects/webpack5_wds5-react/src/AppCompilationError.cy.jsx: Unexpected token, expected "," (8:0) + + 6 | cy.get('h1').contains('Hello World') + 7 | } + > 8 | }) + | ^ + 9 | + [stack trace lines] + + When Cypress detects uncaught errors originating from your test code it will automatically fail the current test. + + Cypress could not associate this error to any specific test. + + We dynamically generated a new test to display this failure. + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: AppCompilationError.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/AppCompilationError.cy.jsx/An uncaught error wa (1280x633) + s detected outside of a test (failed).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: Errors.cy.jsx (3 of 9) + + + Errors + 1) error on mount + 2) sync error + 3) async error + 4) command failure + + + 0 passing + 4 failing + + 1) Errors + error on mount: + Error: The following error originated from your application code, not from Cypress. + + > mount error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 2) Errors + sync error: + Error: The following error originated from your application code, not from Cypress. + + > sync error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 3) Errors + async error: + Error: The following error originated from your application code, not from Cypress. + + > async error + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + 4) Errors + command failure: + AssertionError: Timed out retrying after 50ms: Expected to find element: \`element-that-does-not-exist\`, but never found it. + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 4 │ + │ Passing: 0 │ + │ Failing: 4 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 4 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: Errors.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- error on mount (failed) (1280x633) + .png + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- sync error (failed).png (1280x633) + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- async error (failed).pn (1280x633) + g + - /XXX/XXX/XXX/cypress/screenshots/Errors.cy.jsx/Errors -- command failure (failed (1280x633) + ).png + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: MissingReact.cy.jsx (4 of 9) + + + 1) is missing React + + 0 passing + 1 failing + + 1) is missing React: + ReferenceError: The following error originated from your application code, not from Cypress. + + > React is not defined + +When Cypress detects uncaught errors originating from your application it will automatically fail the current test. + +This behavior is configurable, and you can choose to turn this off by listening to the \`uncaught:exception\` event. + +https://on.cypress.io/uncaught-exception-from-application + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: MissingReact.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/MissingReact.cy.jsx/is missing React (failed).p (1280x633) + ng + + +──────────────────────────────────────────────────────────────────────────────────────────────────── + + Running: MissingReactInSpec.cy.jsx (5 of 9) + + + 1) is missing React in this file + + 0 passing + 1 failing + + 1) is missing React in this file: + ReferenceError: React is not defined + [stack trace lines] + + + + + (Results) + + ┌────────────────────────────────────────────────────────────────────────────────────────────────┐ + │ Tests: 1 │ + │ Passing: 0 │ + │ Failing: 1 │ + │ Pending: 0 │ + │ Skipped: 0 │ + │ Screenshots: 1 │ + │ Video: false │ + │ Duration: X seconds │ + │ Spec Ran: MissingReactInSpec.cy.jsx │ + └────────────────────────────────────────────────────────────────────────────────────────────────┘ + + + (Screenshots) + + - /XXX/XXX/XXX/cypress/screenshots/MissingReactInSpec.cy.jsx/is missing React in t (1280x633) his file (failed).png diff --git a/system-tests/lib/normalizeStdout.ts b/system-tests/lib/normalizeStdout.ts index 77d960b57c..99a3cd57ff 100644 --- a/system-tests/lib/normalizeStdout.ts +++ b/system-tests/lib/normalizeStdout.ts @@ -165,7 +165,7 @@ export const normalizeStdout = function (str: string, options: any = {}) { // Replaces connection warning since Chrome or Firefox sometimes take longer to connect .replace(/Still waiting to connect to .+, retrying in 1 second \(attempt .+\/.+\)\n/g, '') // Replaces CDP connection error message in Firefox since Cypress will retry - .replace(/Failed to spawn CDP with Firefox. Retrying.*\.\.\./, '') + .replace(/\nFailed to spawn CDP with Firefox. Retrying.*\.\.\.\n/g, '') if (options.browser === 'webkit') { // WebKit throws for lookups on undefined refs with "Can't find variable: " diff --git a/tooling/v8-snapshot/cache/darwin/snapshot-meta.json b/tooling/v8-snapshot/cache/darwin/snapshot-meta.json index 37a3c86753..d3d916a982 100644 --- a/tooling/v8-snapshot/cache/darwin/snapshot-meta.json +++ b/tooling/v8-snapshot/cache/darwin/snapshot-meta.json @@ -772,7 +772,7 @@ "./packages/server/lib/plugins/preprocessor.js", "./packages/server/lib/plugins/run_events.js", "./packages/server/lib/reporter.js", - "./packages/server/lib/screenshots.js", + "./packages/server/lib/screenshots.ts", "./packages/server/lib/util/chrome_policy_check.js", "./packages/server/lib/util/cookies.ts", "./packages/server/lib/util/fs.ts", @@ -4181,5 +4181,5 @@ "./tooling/v8-snapshot/cache/darwin/snapshot-entry.js" ], "deferredHashFile": "yarn.lock", - "deferredHash": "e596be1821cc2b05713da07adece7ebc715adb9bbff1e38299c2d35db61ed3a4" + "deferredHash": "3f244751459328929504043ad557cf01df1c72ec53ee8aee2567bec96724c0db" } \ No newline at end of file diff --git a/tooling/v8-snapshot/cache/linux/snapshot-meta.json b/tooling/v8-snapshot/cache/linux/snapshot-meta.json index f0e612f361..a2566162f2 100644 --- a/tooling/v8-snapshot/cache/linux/snapshot-meta.json +++ b/tooling/v8-snapshot/cache/linux/snapshot-meta.json @@ -771,7 +771,7 @@ "./packages/server/lib/plugins/preprocessor.js", "./packages/server/lib/plugins/run_events.js", "./packages/server/lib/reporter.js", - "./packages/server/lib/screenshots.js", + "./packages/server/lib/screenshots.ts", "./packages/server/lib/util/chrome_policy_check.js", "./packages/server/lib/util/cookies.ts", "./packages/server/lib/util/fs.ts", @@ -4184,5 +4184,5 @@ "./tooling/v8-snapshot/cache/linux/snapshot-entry.js" ], "deferredHashFile": "yarn.lock", - "deferredHash": "e596be1821cc2b05713da07adece7ebc715adb9bbff1e38299c2d35db61ed3a4" + "deferredHash": "3f244751459328929504043ad557cf01df1c72ec53ee8aee2567bec96724c0db" } \ No newline at end of file diff --git a/tooling/v8-snapshot/cache/win32/snapshot-meta.json b/tooling/v8-snapshot/cache/win32/snapshot-meta.json index 74c3c00244..67ffd9374a 100644 --- a/tooling/v8-snapshot/cache/win32/snapshot-meta.json +++ b/tooling/v8-snapshot/cache/win32/snapshot-meta.json @@ -773,7 +773,7 @@ "./packages/server/lib/plugins/preprocessor.js", "./packages/server/lib/plugins/run_events.js", "./packages/server/lib/reporter.js", - "./packages/server/lib/screenshots.js", + "./packages/server/lib/screenshots.ts", "./packages/server/lib/util/chrome_policy_check.js", "./packages/server/lib/util/cookies.ts", "./packages/server/lib/util/fs.ts", @@ -4184,5 +4184,5 @@ "./tooling/v8-snapshot/cache/win32/snapshot-entry.js" ], "deferredHashFile": "yarn.lock", - "deferredHash": "d4df8732c497d2eb66aecb340b5ae752b7c18f38387c281738ccb1ddf0e6a45a" + "deferredHash": "9c8930c204e820609bac39267ab2522614df37c32c20c03fcb17c6daf96159f3" } \ No newline at end of file diff --git a/yarn.lock b/yarn.lock index dca6ecf379..27f31ad822 100644 --- a/yarn.lock +++ b/yarn.lock @@ -11339,8 +11339,8 @@ brorand@^1.0.1, brorand@^1.1.0: integrity sha1-EsJe/kCkXjwyPrhnWgoM5XsiNx8= "browser-logos@github:alrra/browser-logos": - version "72.0.0" - resolved "https://codeload.github.com/alrra/browser-logos/tar.gz/6e3e6a8da0dc8ec9851a6987fd9bd3523fe1876c" + version "75.0.0" + resolved "https://codeload.github.com/alrra/browser-logos/tar.gz/021a9533c9d872dccf92713f59afb383b29a50eb" browser-resolve@2.0.0: version "2.0.0" @@ -22644,7 +22644,7 @@ mobx@6.13.5: resolved "https://registry.npmjs.org/mobx/-/mobx-6.13.5.tgz#957d9df88c7f8b4baa7c6f8bdcb6d68b432a6ed5" integrity sha512-/HTWzW2s8J1Gqt+WmUj5Y0mddZk+LInejADc79NJadrWla3rHzmRHki/mnEUH1AvOmbNTZ1BRbKxr8DSgfdjMA== -"mocha-7.0.1@npm:mocha@7.0.1", mocha@7.0.1: +"mocha-7.0.1@npm:mocha@7.0.1": version "7.0.1" resolved "https://registry.yarnpkg.com/mocha/-/mocha-7.0.1.tgz#276186d35a4852f6249808c6dd4a1376cbf6c6ce" integrity sha512-9eWmWTdHLXh72rGrdZjNbG3aa1/3NRPpul1z0D979QpEnFdCG0Q5tv834N+94QEN2cysfV72YocQ3fn87s70fg== @@ -22761,6 +22761,36 @@ mocha@6.2.2: yargs-parser "13.1.1" yargs-unparser "1.6.0" +mocha@7.0.1: + version "7.0.1" + resolved "https://registry.yarnpkg.com/mocha/-/mocha-7.0.1.tgz#276186d35a4852f6249808c6dd4a1376cbf6c6ce" + integrity sha512-9eWmWTdHLXh72rGrdZjNbG3aa1/3NRPpul1z0D979QpEnFdCG0Q5tv834N+94QEN2cysfV72YocQ3fn87s70fg== + dependencies: + ansi-colors "3.2.3" + browser-stdout "1.3.1" + chokidar "3.3.0" + debug "3.2.6" + diff "3.5.0" + escape-string-regexp "1.0.5" + find-up "3.0.0" + glob "7.1.3" + growl "1.10.5" + he "1.2.0" + js-yaml "3.13.1" + log-symbols "2.2.0" + minimatch "3.0.4" + mkdirp "0.5.1" + ms "2.1.1" + node-environment-flags "1.0.6" + object.assign "4.1.0" + strip-json-comments "2.0.1" + supports-color "6.0.0" + which "1.3.1" + wide-align "1.1.3" + yargs "13.3.0" + yargs-parser "13.1.1" + yargs-unparser "1.6.0" + mocha@7.1.0: version "7.1.0" resolved "https://registry.yarnpkg.com/mocha/-/mocha-7.1.0.tgz#c784f579ad0904d29229ad6cb1e2514e4db7d249" @@ -29307,7 +29337,7 @@ string-template@~0.2.1: resolved "https://registry.yarnpkg.com/string-template/-/string-template-0.2.1.tgz#42932e598a352d01fc22ec3367d9d84eec6c9add" integrity sha1-QpMuWYo1LQH8IuwzZ9nYTuxsmt0= -"string-width-cjs@npm:string-width@^4.2.0", "string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.0.0, string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: +"string-width-cjs@npm:string-width@^4.2.0": version "4.2.3" resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== @@ -29333,6 +29363,15 @@ string-width@^1.0.1, string-width@^1.0.2: is-fullwidth-code-point "^2.0.0" strip-ansi "^4.0.0" +"string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.0.0, string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: + version "4.2.3" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + string-width@^3.0.0, string-width@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/string-width/-/string-width-3.1.0.tgz#22767be21b62af1081574306f69ac51b62203961" @@ -29443,7 +29482,7 @@ stringify-object@^3.0.0, stringify-object@^3.3.0: is-obj "^1.0.1" is-regexp "^1.0.0" -"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@6.0.1, strip-ansi@^6.0.0, strip-ansi@^6.0.1: +"strip-ansi-cjs@npm:strip-ansi@^6.0.1": version "6.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== @@ -29464,6 +29503,13 @@ strip-ansi@5.2.0, strip-ansi@^5.0.0, strip-ansi@^5.1.0, strip-ansi@^5.2.0: dependencies: ansi-regex "^4.1.0" +strip-ansi@6.0.1, strip-ansi@^6.0.0, strip-ansi@^6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== + dependencies: + ansi-regex "^5.0.1" + strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" @@ -32493,7 +32539,7 @@ workerpool@6.2.0: resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.2.0.tgz#827d93c9ba23ee2019c3ffaff5c27fccea289e8b" integrity sha512-Rsk5qQHJ9eowMH28Jwhe8HEbmdYDX4lwoMWshiCXugjtHqMD9ZbiqSDLxcsfdqsETPzVUtX5s1Z5kStiIM6l4A== -"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0: +"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== @@ -32536,6 +32582,15 @@ wrap-ansi@^6.2.0: string-width "^4.1.0" strip-ansi "^6.0.0" +wrap-ansi@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" + integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== + dependencies: + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" + wrap-ansi@^8.0.1, wrap-ansi@^8.1.0: version "8.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-8.1.0.tgz#56dc22368ee570face1b49819975d9b9a5ead214"