cypress 8.6.0 → 8.7.0

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cypress",
3
- "version": "8.6.0",
3
+ "version": "8.7.0",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "postinstall": "node index.js --exec install",
@@ -1,11 +1,12 @@
1
1
  // Shim definition to export a namespace. Cypress is actually a global module
2
2
  // so import/export isn't allowed there. We import here and define a global module
3
3
  // so that Cypress can get and use the Blob type
4
- import BluebirdStatic = require('./bluebird')
4
+ import ImportedBluebird = require('./bluebird')
5
5
 
6
6
  export = Bluebird
7
7
  export as namespace Bluebird
8
8
 
9
9
  declare namespace Bluebird {
10
- type BluebirdStatic = typeof BluebirdStatic
10
+ type BluebirdStatic = typeof ImportedBluebird
11
+ interface Promise<T> extends ImportedBluebird<T> {}
11
12
  }
@@ -91,6 +91,10 @@ declare namespace CypressCommandLine {
91
91
  * Specify mocha reporter options
92
92
  */
93
93
  reporterOptions: any
94
+ /**
95
+ * Slow test threshold in milliseconds. Only affects the visual output of some reporters. For example, the spec reporter will display the test time in yellow if over the threshold.
96
+ */
97
+ slowTestThreshold: number
94
98
  /**
95
99
  * Specify the specs to run
96
100
  */
@@ -170,6 +170,11 @@ declare namespace Cypress {
170
170
  */
171
171
  interface ApplicationWindow { } // tslint:disable-line
172
172
 
173
+ /**
174
+ * The configuration for Cypress.
175
+ */
176
+ type Config = ResolvedConfigOptions & RuntimeConfigOptions
177
+
173
178
  /**
174
179
  * Several libraries are bundled with Cypress by default.
175
180
  *
@@ -297,7 +302,7 @@ declare namespace Cypress {
297
302
  /**
298
303
  * Fire automation:request event for internal use.
299
304
  */
300
- automation(eventName: string, ...args: any[]): Promise<any>
305
+ automation(eventName: string, ...args: any[]): Bluebird.Promise<any>
301
306
 
302
307
  /**
303
308
  * Promise wrapper for certain internal tasks.
@@ -313,7 +318,7 @@ declare namespace Cypress {
313
318
  // {defaultCommandTimeout: 10000, pageLoadTimeout: 30000, ...}
314
319
  ```
315
320
  */
316
- config(): ResolvedConfigOptions & RuntimeConfigOptions
321
+ config(): Config
317
322
  /**
318
323
  * Returns one configuration value.
319
324
  * @see https://on.cypress.io/config
@@ -2572,6 +2577,11 @@ declare namespace Cypress {
2572
2577
  * @default "spec"
2573
2578
  */
2574
2579
  reporterOptions: { [key: string]: any }
2580
+ /**
2581
+ * Slow test threshold in milliseconds. Only affects the visual output of some reporters. For example, the spec reporter will display the test time in yellow if over the threshold.
2582
+ * @default 10000
2583
+ */
2584
+ slowTestThreshold: number
2575
2585
  /**
2576
2586
  * Whether Cypress will watch and restart tests on test file changes
2577
2587
  * @default true