cypress 9.4.0 → 9.4.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -1949,8 +1949,8 @@ declare module "chai" {
1949
1949
  export = chai;
1950
1950
  }
1951
1951
 
1952
- // const a = 1; a.should(1); doesn't work with Cypress
1953
- // https://github.com/cypress-io/cypress/issues/16548
1954
- // interface Object {
1955
- // should: Chai.Assertion;
1956
- // }
1952
+ // const a = 1; a.should(1); doesn't work with Cypress
1953
+ // https://github.com/cypress-io/cypress/issues/16548
1954
+ // interface Object {
1955
+ // should: Chai.Assertion;
1956
+ // }
@@ -1,13 +1,13 @@
1
- // Shim definition to export a namespace. Cypress is actually a global module
2
- // so import/export isn't allowed there. We import here and define a global module
3
- // so that Cypress can get and use the Blob type
4
-
5
- // tslint:disable-next-line:no-implicit-dependencies
6
- import * as blobUtil from 'blob-util'
7
-
8
- export = BlobUtil
9
- export as namespace BlobUtil
10
-
11
- declare namespace BlobUtil {
12
- type BlobUtilStatic = typeof blobUtil
13
- }
1
+ // Shim definition to export a namespace. Cypress is actually a global module
2
+ // so import/export isn't allowed there. We import here and define a global module
3
+ // so that Cypress can get and use the Blob type
4
+
5
+ // tslint:disable-next-line:no-implicit-dependencies
6
+ import * as blobUtil from 'blob-util'
7
+
8
+ export = BlobUtil
9
+ export as namespace BlobUtil
10
+
11
+ declare namespace BlobUtil {
12
+ type BlobUtilStatic = typeof blobUtil
13
+ }
@@ -1,12 +1,12 @@
1
- // Shim definition to export a namespace. Cypress is actually a global module
2
- // so import/export isn't allowed there. We import here and define a global module
3
- // so that Cypress can get and use the Blob type
4
- import ImportedBluebird = require('./bluebird')
5
-
6
- export = Bluebird
7
- export as namespace Bluebird
8
-
9
- declare namespace Bluebird {
10
- type BluebirdStatic = typeof ImportedBluebird
11
- interface Promise<T> extends ImportedBluebird<T> {}
12
- }
1
+ // Shim definition to export a namespace. Cypress is actually a global module
2
+ // so import/export isn't allowed there. We import here and define a global module
3
+ // so that Cypress can get and use the Blob type
4
+ import ImportedBluebird = require('./bluebird')
5
+
6
+ export = Bluebird
7
+ export as namespace Bluebird
8
+
9
+ declare namespace Bluebird {
10
+ type BluebirdStatic = typeof ImportedBluebird
11
+ interface Promise<T> extends ImportedBluebird<T> {}
12
+ }
@@ -1,10 +1,10 @@
1
- // Shim definition to export a namespace. Cypress is actually a global module
2
- // so import/export isn't allowed there. We import here and define a global module
3
- /// <reference path="./chai/index.d.ts" />
4
- declare namespace Chai {
5
- interface Include {
6
- html(html: string): Assertion
7
- text(text: string): Assertion
8
- value(text: string): Assertion
9
- }
10
- }
1
+ // Shim definition to export a namespace. Cypress is actually a global module
2
+ // so import/export isn't allowed there. We import here and define a global module
3
+ /// <reference path="./chai/index.d.ts" />
4
+ declare namespace Chai {
5
+ interface Include {
6
+ html(html: string): Assertion
7
+ text(text: string): Assertion
8
+ value(text: string): Assertion
9
+ }
10
+ }
@@ -1,13 +1,13 @@
1
- /**
2
- * This file should be deleted as soon as the serever
3
- * TODO: delete this file when ResolvedDevServerConfig.server is converted to closeServer
4
- */
5
-
6
- /// <reference types="node" />
7
- import * as cyUtilsHttp from 'http'
8
- export = cyUtilsHttp
9
- /**
10
- * namespace created to bridge nodeJs.http typings so that
11
- * we can type http Server in CT
12
- */
13
- export as namespace cyUtilsHttp
1
+ /**
2
+ * This file should be deleted as soon as the serever
3
+ * TODO: delete this file when ResolvedDevServerConfig.server is converted to closeServer
4
+ */
5
+
6
+ /// <reference types="node" />
7
+ import * as cyUtilsHttp from 'http'
8
+ export = cyUtilsHttp
9
+ /**
10
+ * namespace created to bridge nodeJs.http typings so that
11
+ * we can type http Server in CT
12
+ */
13
+ export as namespace cyUtilsHttp
@@ -1,96 +1,96 @@
1
- // I was trying to avoid relying on "import" of actual module from "minimatch"
2
- // because it would not work in test project, and the only reliable way
3
- // to get around type errors finally was to copy the minimal minimatch function
4
- // definition from "minimatch/index.d.ts" here and just keep it in our code
5
-
6
- export = Minimatch
7
- export as namespace Minimatch
8
-
9
- interface MinimatchOptions {
10
- /**
11
- * Dump a ton of stuff to stderr.
12
- *
13
- * @default false
14
- */
15
- debug?: boolean
16
-
17
- /**
18
- * Do not expand {a,b} and {1..3} brace sets.
19
- *
20
- * @default false
21
- */
22
- nobrace?: boolean
23
-
24
- /**
25
- * Disable ** matching against multiple folder names.
26
- *
27
- * @default false
28
- */
29
- noglobstar?: boolean
30
-
31
- /**
32
- * Allow patterns to match filenames starting with a period,
33
- * even if the pattern does not explicitly have a period in that spot.
34
- *
35
- * @default false
36
- */
37
- dot?: boolean
38
-
39
- /**
40
- * Disable "extglob" style patterns like +(a|b).
41
- *
42
- * @default false
43
- */
44
- noext?: boolean
45
-
46
- /**
47
- * Perform a case-insensitive match.
48
- *
49
- * @default false
50
- */
51
- nocase?: boolean
52
-
53
- /**
54
- * When a match is not found by minimatch.match,
55
- * return a list containing the pattern itself if this option is set.
56
- * Otherwise, an empty list is returned if there are no matches.
57
- *
58
- * @default false
59
- */
60
- nonull?: boolean
61
-
62
- /**
63
- * If set, then patterns without slashes will be matched against
64
- * the basename of the path if it contains slashes.
65
- *
66
- * @default false
67
- */
68
- matchBase?: boolean
69
-
70
- /**
71
- * Suppress the behavior of treating #
72
- * at the start of a pattern as a comment.
73
- *
74
- * @default false
75
- */
76
- nocomment?: boolean
77
-
78
- /**
79
- * Suppress the behavior of treating a leading ! character as negation.
80
- *
81
- * @default false
82
- */
83
- nonegate?: boolean
84
-
85
- /**
86
- * Returns from negate expressions the same as if they were not negated.
87
- * (Ie, true on a hit, false on a miss.)
88
- *
89
- * @default false
90
- */
91
- flipNegate?: boolean
92
- }
93
-
94
- declare namespace Minimatch {
95
- function minimatch(target: string, pattern: string, options?: MinimatchOptions): boolean
96
- }
1
+ // I was trying to avoid relying on "import" of actual module from "minimatch"
2
+ // because it would not work in test project, and the only reliable way
3
+ // to get around type errors finally was to copy the minimal minimatch function
4
+ // definition from "minimatch/index.d.ts" here and just keep it in our code
5
+
6
+ export = Minimatch
7
+ export as namespace Minimatch
8
+
9
+ interface MinimatchOptions {
10
+ /**
11
+ * Dump a ton of stuff to stderr.
12
+ *
13
+ * @default false
14
+ */
15
+ debug?: boolean
16
+
17
+ /**
18
+ * Do not expand {a,b} and {1..3} brace sets.
19
+ *
20
+ * @default false
21
+ */
22
+ nobrace?: boolean
23
+
24
+ /**
25
+ * Disable ** matching against multiple folder names.
26
+ *
27
+ * @default false
28
+ */
29
+ noglobstar?: boolean
30
+
31
+ /**
32
+ * Allow patterns to match filenames starting with a period,
33
+ * even if the pattern does not explicitly have a period in that spot.
34
+ *
35
+ * @default false
36
+ */
37
+ dot?: boolean
38
+
39
+ /**
40
+ * Disable "extglob" style patterns like +(a|b).
41
+ *
42
+ * @default false
43
+ */
44
+ noext?: boolean
45
+
46
+ /**
47
+ * Perform a case-insensitive match.
48
+ *
49
+ * @default false
50
+ */
51
+ nocase?: boolean
52
+
53
+ /**
54
+ * When a match is not found by minimatch.match,
55
+ * return a list containing the pattern itself if this option is set.
56
+ * Otherwise, an empty list is returned if there are no matches.
57
+ *
58
+ * @default false
59
+ */
60
+ nonull?: boolean
61
+
62
+ /**
63
+ * If set, then patterns without slashes will be matched against
64
+ * the basename of the path if it contains slashes.
65
+ *
66
+ * @default false
67
+ */
68
+ matchBase?: boolean
69
+
70
+ /**
71
+ * Suppress the behavior of treating #
72
+ * at the start of a pattern as a comment.
73
+ *
74
+ * @default false
75
+ */
76
+ nocomment?: boolean
77
+
78
+ /**
79
+ * Suppress the behavior of treating a leading ! character as negation.
80
+ *
81
+ * @default false
82
+ */
83
+ nonegate?: boolean
84
+
85
+ /**
86
+ * Returns from negate expressions the same as if they were not negated.
87
+ * (Ie, true on a hit, false on a miss.)
88
+ *
89
+ * @default false
90
+ */
91
+ flipNegate?: boolean
92
+ }
93
+
94
+ declare namespace Minimatch {
95
+ function minimatch(target: string, pattern: string, options?: MinimatchOptions): boolean
96
+ }
@@ -1,33 +1,33 @@
1
- // Cypress, cy, Log inherits EventEmitter.
2
- type EventEmitter2 = import("eventemitter2").EventEmitter2
3
-
4
- interface EventEmitter extends EventEmitter2 {
5
- proxyTo: (cy: Cypress.cy) => null
6
- emitMap: (eventName: string, args: any[]) => Array<(...args: any[]) => any>
7
- emitThen: (eventName: string, args: any[]) => Bluebird.BluebirdStatic
8
- }
9
-
10
- // Copied from https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/node/events.d.ts
11
- // to avoid type conflict.
12
- interface NodeEventEmitter {
13
- addListener(event: string | symbol, listener: (...args: any[]) => void): this
14
- on(event: string | symbol, listener: (...args: any[]) => void): this
15
- once(event: string | symbol, listener: (...args: any[]) => void): this
16
- removeListener(event: string | symbol, listener: (...args: any[]) => void): this
17
- off(event: string | symbol, listener: (...args: any[]) => void): this
18
- removeAllListeners(event?: string | symbol): this
19
- setMaxListeners(n: number): this
20
- getMaxListeners(): number
21
- listeners(event: string | symbol): Array<(...args: any[]) => void>
22
- rawListeners(event: string | symbol): Array<(...args: any[]) => void>
23
- emit(event: string | symbol, ...args: any[]): boolean
24
- listenerCount(type: string | symbol): number
25
- // Added in Node 6...
26
- prependListener(event: string | symbol, listener: (...args: any[]) => void): this
27
- prependOnceListener(event: string | symbol, listener: (...args: any[]) => void): this
28
- eventNames(): Array<string | symbol>
29
- }
30
-
31
- // We use the Buffer class for dealing with binary data, especially around the
32
- // selectFile interface.
33
- type BufferType = import("buffer/").Buffer
1
+ // Cypress, cy, Log inherits EventEmitter.
2
+ type EventEmitter2 = import("eventemitter2").EventEmitter2
3
+
4
+ interface EventEmitter extends EventEmitter2 {
5
+ proxyTo: (cy: Cypress.cy) => null
6
+ emitMap: (eventName: string, args: any[]) => Array<(...args: any[]) => any>
7
+ emitThen: (eventName: string, args: any[]) => Bluebird.BluebirdStatic
8
+ }
9
+
10
+ // Copied from https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/node/events.d.ts
11
+ // to avoid type conflict.
12
+ interface NodeEventEmitter {
13
+ addListener(event: string | symbol, listener: (...args: any[]) => void): this
14
+ on(event: string | symbol, listener: (...args: any[]) => void): this
15
+ once(event: string | symbol, listener: (...args: any[]) => void): this
16
+ removeListener(event: string | symbol, listener: (...args: any[]) => void): this
17
+ off(event: string | symbol, listener: (...args: any[]) => void): this
18
+ removeAllListeners(event?: string | symbol): this
19
+ setMaxListeners(n: number): this
20
+ getMaxListeners(): number
21
+ listeners(event: string | symbol): Array<(...args: any[]) => void>
22
+ rawListeners(event: string | symbol): Array<(...args: any[]) => void>
23
+ emit(event: string | symbol, ...args: any[]): boolean
24
+ listenerCount(type: string | symbol): number
25
+ // Added in Node 6...
26
+ prependListener(event: string | symbol, listener: (...args: any[]) => void): this
27
+ prependOnceListener(event: string | symbol, listener: (...args: any[]) => void): this
28
+ eventNames(): Array<string | symbol>
29
+ }
30
+
31
+ // We use the Buffer class for dealing with binary data, especially around the
32
+ // selectFile interface.
33
+ type BufferType = import("buffer/").Buffer
@@ -1,3 +1,3 @@
1
- // Cypress adds chai expect and assert to global
2
- declare const expect: Chai.ExpectStatic
3
- declare const assert: Chai.AssertStatic
1
+ // Cypress adds chai expect and assert to global
2
+ declare const expect: Chai.ExpectStatic
3
+ declare const assert: Chai.AssertStatic
@@ -1,22 +1,22 @@
1
- /**
2
- * Global variables `cy` added by Cypress with all API commands.
3
- * @see https://on.cypress.io/api
4
- *
5
- ```
6
- cy.get('button').click()
7
- cy.get('.result').contains('Expected text')
8
- ```
9
- */
10
- declare const cy: Cypress.cy & EventEmitter
11
-
12
- /**
13
- * Global variable `Cypress` holds common utilities and constants.
14
- * @see https://on.cypress.io/api
15
- *
16
- ```
17
- Cypress.config("pageLoadTimeout") // => 60000
18
- Cypress.version // => "1.4.0"
19
- Cypress._ // => Lodash _
20
- ```
21
- */
22
- declare const Cypress: Cypress.Cypress & EventEmitter
1
+ /**
2
+ * Global variables `cy` added by Cypress with all API commands.
3
+ * @see https://on.cypress.io/api
4
+ *
5
+ ```
6
+ cy.get('button').click()
7
+ cy.get('.result').contains('Expected text')
8
+ ```
9
+ */
10
+ declare const cy: Cypress.cy & EventEmitter
11
+
12
+ /**
13
+ * Global variable `Cypress` holds common utilities and constants.
14
+ * @see https://on.cypress.io/api
15
+ *
16
+ ```
17
+ Cypress.config("pageLoadTimeout") // => 60000
18
+ Cypress.version // => "1.4.0"
19
+ Cypress._ // => Lodash _
20
+ ```
21
+ */
22
+ declare const Cypress: Cypress.Cypress & EventEmitter