cypress 11.1.0 → 11.2.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -8,7 +8,8 @@
8
8
  "build": "rollup -c rollup.config.mjs",
9
9
  "postbuild": "node ../../scripts/sync-exported-npm-with-cli.js",
10
10
  "build-prod": "yarn build",
11
- "check-ts": "tsc --noEmit"
11
+ "check-ts": "tsc --noEmit",
12
+ "lint": "eslint --ext .js,.ts,.json, ."
12
13
  },
13
14
  "dependencies": {},
14
15
  "devDependencies": {
package/lib/cli.js CHANGED
@@ -123,7 +123,7 @@ const descriptions = {
123
123
  exit: 'keep the browser open after tests finish',
124
124
  forceInstall: 'force install the Cypress binary',
125
125
  global: 'force Cypress into global mode as if its globally installed',
126
- group: 'a named group for recorded runs in the Cypress Dashboard',
126
+ group: 'a named group for recorded runs in Cypress Cloud',
127
127
  headed: 'displays the browser instead of running headlessly',
128
128
  headless: 'hide the browser instead of running headed (default for cypress run)',
129
129
  key: 'your secret Record Key. you can omit this if you set a CYPRESS_RECORD_KEY environment variable.',
@@ -131,11 +131,11 @@ const descriptions = {
131
131
  port: 'runs Cypress on a specific port. overrides any value in cypress.config.{js,ts,mjs,cjs}.',
132
132
  project: 'path to the project',
133
133
  quiet: 'run quietly, using only the configured reporter',
134
- record: 'records the run. sends test results, screenshots and videos to your Cypress Dashboard.',
134
+ record: 'records the run. sends test results, screenshots and videos to Cypress Cloud.',
135
135
  reporter: 'runs a specific mocha reporter. pass a path to use a custom reporter. defaults to "spec"',
136
136
  reporterOptions: 'options for the mocha reporter. defaults to "null"',
137
137
  spec: 'runs specific spec file(s). defaults to "all"',
138
- tag: 'named tag(s) for recorded runs in the Cypress Dashboard',
138
+ tag: 'named tag(s) for recorded runs in Cypress Cloud',
139
139
  version: 'prints Cypress version'
140
140
  };
141
141
  const knownCommands = ['cache', 'help', '-h', '--help', 'install', 'open', 'run', 'open-ct', 'run-ct', 'verify', '-v', '--version', 'version', 'info'];
@@ -8,7 +8,8 @@
8
8
  "postbuild": "node ../../scripts/sync-exported-npm-with-cli.js",
9
9
  "build-prod": "yarn build",
10
10
  "check-ts": "tsc --noEmit",
11
- "watch": "tsc -w"
11
+ "watch": "tsc -w",
12
+ "lint": "eslint --ext .js,.ts,.json, ."
12
13
  },
13
14
  "dependencies": {},
14
15
  "devDependencies": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cypress",
3
- "version": "11.1.0",
3
+ "version": "11.2.0",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "postinstall": "node index.js --exec install",
@@ -118,8 +118,8 @@
118
118
  },
119
119
  "buildInfo": {
120
120
  "commitBranch": "develop",
121
- "commitSha": "cea2664a26da06655017e51f4911ea505a6b685b",
122
- "commitDate": "2022-11-15T15:41:42.000Z",
121
+ "commitSha": "4bbd78e22e99ae72e909a45c8ff5e8c3fd7d61ef",
122
+ "commitDate": "2022-11-22T07:28:48.000Z",
123
123
  "stable": true
124
124
  },
125
125
  "description": "Cypress is a next generation front end testing tool built for the modern web",
@@ -12,6 +12,7 @@
12
12
  "cy:run": "node ../../scripts/cypress.js run --component",
13
13
  "cy:run:debug": "node --inspect-brk ../../scripts/start.js --component-testing --run-project ${PWD}",
14
14
  "test": "yarn cy:run",
15
+ "lint": "eslint --ext .js,.jsx,.ts,.tsx,.json, .",
15
16
  "watch": "yarn build --watch --watch.exclude ./dist/**/*"
16
17
  },
17
18
  "devDependencies": {
@@ -7,7 +7,8 @@
7
7
  "build": "rimraf dist && rollup -c rollup.config.mjs",
8
8
  "postbuild": "node ../../scripts/sync-exported-npm-with-cli.js",
9
9
  "build-prod": "yarn build",
10
- "watch": "yarn build --watch --watch.exclude ./dist/**/*"
10
+ "watch": "yarn build --watch --watch.exclude ./dist/**/*",
11
+ "lint": "eslint --ext .js,.jsx,.ts,.tsx,.json, ."
11
12
  },
12
13
  "devDependencies": {
13
14
  "@cypress/mount-utils": "0.0.0-development",
@@ -8,6 +8,7 @@
8
8
  "build": "rollup -c rollup.config.mjs",
9
9
  "postbuild": "node ../../scripts/sync-exported-npm-with-cli.js",
10
10
  "build-prod": "yarn build",
11
+ "lint": "eslint --ext .js,.jsx,.ts,.tsx,.json, .",
11
12
  "check-ts": "tsc --noEmit"
12
13
  },
13
14
  "devDependencies": {
@@ -229,6 +229,7 @@ declare namespace CypressCommandLine {
229
229
  startedAt: dateTimeISO
230
230
  endedAt: dateTimeISO
231
231
  duration: ms
232
+ wallClockDuration?: number
232
233
  }
233
234
  /**
234
235
  * Reporter name like "spec"
@@ -259,8 +260,10 @@ declare namespace CypressCommandLine {
259
260
  * resolved filename of the spec
260
261
  */
261
262
  absolute: string
263
+ relativeToCommonRoot: string
262
264
  }
263
265
  shouldUploadVideo: boolean
266
+ skippedSpec: boolean
264
267
  }
265
268
 
266
269
  /**
@@ -1,3 +1,4 @@
1
+ /* eslint-disable @typescript-eslint/no-unused-vars */
1
2
  /// <reference path="./cypress-npm-api.d.ts" />
2
3
  /// <reference path="./cypress-eventemitter.d.ts" />
3
4
  /// <reference path="./cypress-type-helpers.d.ts" />
@@ -470,19 +471,19 @@ declare namespace Cypress {
470
471
  add<T extends keyof Chainable>(name: T, options: CommandOptions & {prevSubject: false}, fn: CommandFn<T>): void
471
472
  add<T extends keyof Chainable, S = any>(name: T, options: CommandOptions & {prevSubject: true}, fn: CommandFnWithSubject<T, S>): void
472
473
  add<T extends keyof Chainable, S extends PrevSubject>(
473
- name: T, options: CommandOptions & { prevSubject: S | ['optional'] }, fn: CommandFnWithSubject<T, PrevSubjectMap[S]>,
474
+ name: T, options: CommandOptions & { prevSubject: S | ['optional'] }, fn: CommandFnWithSubject<T, PrevSubjectMap[S]>,
474
475
  ): void
475
476
  add<T extends keyof Chainable, S extends PrevSubject>(
476
- name: T, options: CommandOptions & { prevSubject: S[] }, fn: CommandFnWithSubject<T, PrevSubjectMap<void>[S]>,
477
+ name: T, options: CommandOptions & { prevSubject: S[] }, fn: CommandFnWithSubject<T, PrevSubjectMap<void>[S]>,
477
478
  ): void
478
479
  addAll<T extends keyof Chainable>(fns: CommandFns): void
479
480
  addAll<T extends keyof Chainable>(options: CommandOptions & {prevSubject: false}, fns: CommandFns): void
480
481
  addAll<T extends keyof Chainable, S = any>(options: CommandOptions & { prevSubject: true }, fns: CommandFnsWithSubject<S>): void
481
482
  addAll<T extends keyof Chainable, S extends PrevSubject>(
482
- options: CommandOptions & { prevSubject: S | ['optional'] }, fns: CommandFnsWithSubject<PrevSubjectMap[S]>,
483
+ options: CommandOptions & { prevSubject: S | ['optional'] }, fns: CommandFnsWithSubject<PrevSubjectMap[S]>,
483
484
  ): void
484
485
  addAll<T extends keyof Chainable, S extends PrevSubject>(
485
- options: CommandOptions & { prevSubject: S[] }, fns: CommandFnsWithSubject<PrevSubjectMap<void>[S]>,
486
+ options: CommandOptions & { prevSubject: S[] }, fns: CommandFnsWithSubject<PrevSubjectMap<void>[S]>,
486
487
  ): void
487
488
  overwrite<T extends keyof Chainable>(name: T, fn: CommandFnWithOriginalFn<T>): void
488
489
  overwrite<T extends keyof Chainable, S extends PrevSubject>(name: T, fn: CommandFnWithOriginalFnAndSubject<T, PrevSubjectMap[S]>): void
@@ -659,7 +660,7 @@ declare namespace Cypress {
659
660
  * Whether or not to persist the session across all specs in the run.
660
661
  * @default {false}
661
662
  */
662
- cacheAcrossSpecs?: boolean,
663
+ cacheAcrossSpecs?: boolean
663
664
  /**
664
665
  * Function to run immediately after the session is created and `setup` function runs or
665
666
  * after a session is restored and the page is cleared. If this returns `false`, throws an
@@ -676,8 +677,8 @@ declare namespace Cypress {
676
677
  type CanReturnChainable = void | Chainable | Promise<unknown>
677
678
  type ThenReturn<S, R> =
678
679
  R extends void ? Chainable<S> :
679
- R extends R | undefined ? Chainable<S | Exclude<R, undefined>> :
680
- Chainable<S>
680
+ R extends R | undefined ? Chainable<S | Exclude<R, undefined>> :
681
+ Chainable<S>
681
682
 
682
683
  /**
683
684
  * Chainable interface for non-array Subjects
@@ -2373,8 +2374,8 @@ declare namespace Cypress {
2373
2374
 
2374
2375
  type ChainableMethods<Subject = any> = {
2375
2376
  [P in keyof Chainable<Subject>]: Chainable<Subject>[P] extends ((...args: any[]) => any)
2376
- ? Chainable<Subject>[P]
2377
- : never
2377
+ ? Chainable<Subject>[P]
2378
+ : never
2378
2379
  }
2379
2380
 
2380
2381
  interface SinonSpyAgent<A extends sinon.SinonSpy> {
@@ -2863,7 +2864,7 @@ declare namespace Cypress {
2863
2864
  */
2864
2865
  video: boolean
2865
2866
  /**
2866
- * Whether Cypress will upload the video to the Dashboard even if all tests are passing. This applies only when recording your runs to the Dashboard. Turn this off if you'd like the video uploaded only when there are failing tests.
2867
+ * Whether Cypress will upload the video to Cypress Cloud even if all tests are passing. This applies only when recording your runs to Cypress Cloud. Turn this off if you'd like the video uploaded only when there are failing tests.
2867
2868
  * @default true
2868
2869
  */
2869
2870
  videoUploadOnPasses: boolean
@@ -2982,7 +2983,7 @@ declare namespace Cypress {
2982
2983
  * Override default config options for E2E Testing runner.
2983
2984
  * @default {}
2984
2985
  */
2985
- e2e: Omit<CoreConfigOptions, 'indexHtmlFile'>
2986
+ e2e: EndToEndConfigOptions
2986
2987
 
2987
2988
  /**
2988
2989
  * An array of objects defining the certificates
@@ -2997,6 +2998,14 @@ declare namespace Cypress {
2997
2998
  indexHtmlFile: string
2998
2999
  }
2999
3000
 
3001
+ interface EndToEndConfigOptions extends Omit<CoreConfigOptions, 'indexHtmlFile'> {
3002
+ /**
3003
+ * Enables the "Run All Specs" UI feature, allowing the execution of multiple specs sequentially.
3004
+ * @default false
3005
+ */
3006
+ experimentalRunAllSpecs?: boolean
3007
+ }
3008
+
3000
3009
  /**
3001
3010
  * Options appended to config object on runtime.
3002
3011
  */
@@ -3112,15 +3121,15 @@ declare namespace Cypress {
3112
3121
  type PickConfigOpt<T> = T extends keyof DefineDevServerConfig ? DefineDevServerConfig[T] : any
3113
3122
 
3114
3123
  interface AngularDevServerProjectConfig {
3115
- root: string,
3116
- sourceRoot: string,
3124
+ root: string
3125
+ sourceRoot: string
3117
3126
  buildOptions: Record<string, any>
3118
3127
  }
3119
3128
 
3120
3129
  type DevServerFn<ComponentDevServerOpts = any> = (cypressDevServerConfig: DevServerConfig, devServerConfig: ComponentDevServerOpts) => ResolvedDevServerConfig | Promise<ResolvedDevServerConfig>
3121
3130
 
3122
3131
  type ConfigHandler<T> = T
3123
- | (() => T | Promise<T>)
3132
+ | (() => T | Promise<T>)
3124
3133
 
3125
3134
  type DevServerConfigOptions = {
3126
3135
  bundler: 'webpack'
@@ -3131,9 +3140,9 @@ declare namespace Cypress {
3131
3140
  framework: 'react' | 'vue' | 'svelte'
3132
3141
  viteConfig?: ConfigHandler<Omit<Exclude<PickConfigOpt<'viteConfig'>, undefined>, 'base' | 'root'>>
3133
3142
  } | {
3134
- bundler: 'webpack',
3135
- framework: 'angular',
3136
- webpackConfig?: ConfigHandler<PickConfigOpt<'webpackConfig'>>,
3143
+ bundler: 'webpack'
3144
+ framework: 'angular'
3145
+ webpackConfig?: ConfigHandler<PickConfigOpt<'webpackConfig'>>
3137
3146
  options?: {
3138
3147
  projectConfig: AngularDevServerProjectConfig
3139
3148
  }
@@ -3162,7 +3171,7 @@ declare namespace Cypress {
3162
3171
  /**
3163
3172
  * Hosts mappings to IP addresses.
3164
3173
  */
3165
- hosts?: null | {[key: string]: string}
3174
+ hosts?: null | {[key: string]: string}
3166
3175
  }
3167
3176
 
3168
3177
  interface PluginConfigOptions extends ResolvedConfigOptions, RuntimeConfigOptions {
package/vue/package.json CHANGED
@@ -10,6 +10,8 @@
10
10
  "build": "rimraf dist && rollup -c rollup.config.mjs",
11
11
  "postbuild": "node ../../scripts/sync-exported-npm-with-cli.js",
12
12
  "typecheck": "yarn tsd && vue-tsc --noEmit",
13
+ "check-ts": "yarn tsd && vue-tsc --noEmit",
14
+ "lint": "eslint --ext .js,.jsx,.ts,.tsx,.json,.vue .",
13
15
  "test": "yarn cy:run",
14
16
  "tsd": "yarn build && yarn tsc -p test-tsd/tsconfig.tsd.json",
15
17
  "watch": "yarn build --watch --watch.exclude ./dist/**/*"
package/vue2/package.json CHANGED
@@ -9,7 +9,9 @@
9
9
  "postbuild": "node ../../scripts/sync-exported-npm-with-cli.js",
10
10
  "build-prod": "yarn build",
11
11
  "test": "echo \"Tests for @cypress/vue2 are run from system-tests\"",
12
- "watch": "yarn build --watch --watch.exclude ./dist/**/*"
12
+ "watch": "yarn build --watch --watch.exclude ./dist/**/*",
13
+ "lint": "eslint --ext .js,.jsx,.ts,.tsx,.json,.vue .",
14
+ "test-ci": "node ../../scripts/run-ct-examples.js --examplesList=./examples.env"
13
15
  },
14
16
  "devDependencies": {
15
17
  "@cypress/mount-utils": "0.0.0-development",