webdriverio 8.0.0-alpha.365 → 8.0.0-alpha.412

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -113,8 +113,12 @@ import { KeyAction, PointerAction, WheelAction, BaseActionParams } from '../../u
113
113
  :wheel-action.js
114
114
  it('should scroll using wheel action commands', async () => {
115
115
  console.log(await browser.execute(() => window.scrollY)) // returns 0
116
- await browser.scroll(0, 200)
117
- console.log(await browser.execute(() => window.scrollY)) // returns 200
116
+ await browser.action('wheel').scroll({
117
+ deltaX: 0,
118
+ deltaY: 500,
119
+ duration: 200
120
+ }).perform()
121
+ console.log(await browser.execute(() => window.scrollY)) // returns 500
118
122
  })
119
123
  * </example>
120
124
  *
@@ -1 +1 @@
1
- {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["../../../src/commands/browser/action.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,WAAW,EAAc,gBAAgB,EAAE,MAAM,8BAA8B,CAAA;AAElH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0HG;AACH,MAAM,CAAC,OAAO,UAAU,MAAM,CAC1B,IAAI,EAAE,WAAW,CAAC,OAAO,EACzB,IAAI,EAAE,KAAK,EACX,IAAI,CAAC,EAAE,IAAI,CAAC,gBAAgB,EAAE,IAAI,CAAC,GACpC,SAAS,CAAA;AACZ,MAAM,CAAC,OAAO,UAAU,MAAM,CAC1B,IAAI,EAAE,WAAW,CAAC,OAAO,EACzB,IAAI,EAAE,SAAS,EACf,IAAI,CAAC,EAAE,gBAAgB,GACxB,aAAa,CAAA;AAChB,MAAM,CAAC,OAAO,UAAU,MAAM,CAC1B,IAAI,EAAE,WAAW,CAAC,OAAO,EACzB,IAAI,EAAE,OAAO,EACb,IAAI,CAAC,EAAE,IAAI,CAAC,gBAAgB,EAAE,IAAI,CAAC,GACpC,WAAW,CAAA"}
1
+ {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["../../../src/commands/browser/action.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,WAAW,EAAc,gBAAgB,EAAE,MAAM,8BAA8B,CAAA;AAElH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8HG;AACH,MAAM,CAAC,OAAO,UAAU,MAAM,CAC1B,IAAI,EAAE,WAAW,CAAC,OAAO,EACzB,IAAI,EAAE,KAAK,EACX,IAAI,CAAC,EAAE,IAAI,CAAC,gBAAgB,EAAE,IAAI,CAAC,GACpC,SAAS,CAAA;AACZ,MAAM,CAAC,OAAO,UAAU,MAAM,CAC1B,IAAI,EAAE,WAAW,CAAC,OAAO,EACzB,IAAI,EAAE,SAAS,EACf,IAAI,CAAC,EAAE,gBAAgB,GACxB,aAAa,CAAA;AAChB,MAAM,CAAC,OAAO,UAAU,MAAM,CAC1B,IAAI,EAAE,WAAW,CAAC,OAAO,EACzB,IAAI,EAAE,OAAO,EACb,IAAI,CAAC,EAAE,IAAI,CAAC,gBAAgB,EAAE,IAAI,CAAC,GACpC,WAAW,CAAA"}
@@ -1,5 +1,5 @@
1
1
  /**
2
- * The browser method `addCommand` helps you to write your own set of commands. You can write your command in a synchronous way or in an asynchronous way.
2
+ * The browser method `addCommand` helps you to write your own set of commands.
3
3
  *
4
4
  * :::info
5
5
  *
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  /**
3
- * The browser method `addCommand` helps you to write your own set of commands. You can write your command in a synchronous way or in an asynchronous way.
3
+ * The browser method `addCommand` helps you to write your own set of commands.
4
4
  *
5
5
  * :::info
6
6
  *
@@ -1,12 +1,14 @@
1
1
  /**
2
- * You can use `call` to execute any async action within your test spec. The command itself
3
- * is treated like a synchronous function. It accepts promises and stops the execution until
4
- * the promise has resolved.
2
+ * You can use `call` to execute any async action within your test spec.
3
+ * It accepts promises and stops the execution until the promise has been resolved.
5
4
  *
6
- * This command helps to run asynchronous code within a synchronous context. With
7
- * WebdriverIO deprecating synchronous usage (see [RFC](https://github.com/webdriverio/webdriverio/discussions/6702))
5
+ * :::info
6
+ *
7
+ * With WebdriverIO deprecating synchronous usage (see [RFC](https://github.com/webdriverio/webdriverio/discussions/6702))
8
8
  * this command is not very useful anymore.
9
9
  *
10
+ * :::
11
+ *
10
12
  * <example>
11
13
  :call.js
12
14
  it('some testing here', async () => {
@@ -1 +1 @@
1
- {"version":3,"file":"call.d.ts","sourceRoot":"","sources":["../../../src/commands/browser/call.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,MAAM,CAAC,OAAO,UAAU,IAAI,CAAC,CAAC,EAAG,EAAE,EAAE,MAAM,CAAC,GAAG,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAM5D"}
1
+ {"version":3,"file":"call.d.ts","sourceRoot":"","sources":["../../../src/commands/browser/call.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG;AACH,MAAM,CAAC,OAAO,UAAU,IAAI,CAAC,CAAC,EAAG,EAAE,EAAE,MAAM,CAAC,GAAG,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAM5D"}
@@ -1,12 +1,14 @@
1
1
  /**
2
- * You can use `call` to execute any async action within your test spec. The command itself
3
- * is treated like a synchronous function. It accepts promises and stops the execution until
4
- * the promise has resolved.
2
+ * You can use `call` to execute any async action within your test spec.
3
+ * It accepts promises and stops the execution until the promise has been resolved.
5
4
  *
6
- * This command helps to run asynchronous code within a synchronous context. With
7
- * WebdriverIO deprecating synchronous usage (see [RFC](https://github.com/webdriverio/webdriverio/discussions/6702))
5
+ * :::info
6
+ *
7
+ * With WebdriverIO deprecating synchronous usage (see [RFC](https://github.com/webdriverio/webdriverio/discussions/6702))
8
8
  * this command is not very useful anymore.
9
9
  *
10
+ * :::
11
+ *
10
12
  * <example>
11
13
  :call.js
12
14
  it('some testing here', async () => {
@@ -2,8 +2,7 @@ import type { WaitUntilOptions } from '../../types';
2
2
  /**
3
3
  *
4
4
  * This wait command is your universal weapon if you want to wait on something. It expects a condition
5
- * and waits until that condition is fulfilled with a truthy value. If you use the WDIO testrunner the
6
- * commands within the condition are getting executed synchronously like in your test.
5
+ * and waits until that condition is fulfilled with a truthy value.
7
6
  *
8
7
  * A common example is to wait until a certain element contains a certain text (see example).
9
8
  *
@@ -1 +1 @@
1
- {"version":3,"file":"waitUntil.d.ts","sourceRoot":"","sources":["../../../src/commands/browser/waitUntil.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAA;AAEnD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,MAAM,CAAC,OAAO,UAAU,SAAS,CAC7B,IAAI,EAAE,WAAW,CAAC,OAAO,GAAG,WAAW,CAAC,OAAO,EAC/C,SAAS,EAAE,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,EAC3C,EACI,OAAqC,EACrC,QAAuC,EACvC,UAAU,EACb,GAAE,OAAO,CAAC,gBAAgB,CAAM,GAClC,OAAO,CAAC,IAAI,GAAG,IAAI,CAAC,CA4BtB"}
1
+ {"version":3,"file":"waitUntil.d.ts","sourceRoot":"","sources":["../../../src/commands/browser/waitUntil.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAA;AAEnD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AACH,MAAM,CAAC,OAAO,UAAU,SAAS,CAC7B,IAAI,EAAE,WAAW,CAAC,OAAO,GAAG,WAAW,CAAC,OAAO,EAC/C,SAAS,EAAE,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,EAC3C,EACI,OAAqC,EACrC,QAAuC,EACvC,UAAU,EACb,GAAE,OAAO,CAAC,gBAAgB,CAAM,GAClC,OAAO,CAAC,IAAI,GAAG,IAAI,CAAC,CA4BtB"}
@@ -2,8 +2,7 @@ import Timer from '../../utils/Timer.js';
2
2
  /**
3
3
  *
4
4
  * This wait command is your universal weapon if you want to wait on something. It expects a condition
5
- * and waits until that condition is fulfilled with a truthy value. If you use the WDIO testrunner the
6
- * commands within the condition are getting executed synchronously like in your test.
5
+ * and waits until that condition is fulfilled with a truthy value.
7
6
  *
8
7
  * A common example is to wait until a certain element contains a certain text (see example).
9
8
  *
@@ -14,7 +14,7 @@
14
14
  * @param {String} property name of the element property
15
15
  * @return {Object|String|Boolean|Number|null} the value of the property of the selected element
16
16
  */
17
- export default function getProperty(this: WebdriverIO.Element, property: string): Promise<string | number | boolean | HTMLElement | Element | ChildNode | ParentNode | ((...nodes: (string | Node)[]) => void) | ((...nodes: (string | Node)[]) => void) | {
17
+ export default function getProperty(this: WebdriverIO.Element, property: string): Promise<string | number | boolean | HTMLElement | Element | EventTarget | ChildNode | ParentNode | ((...nodes: (string | Node)[]) => void) | ((...nodes: (string | Node)[]) => void) | {
18
18
  (options?: ScrollToOptions | undefined): void;
19
19
  (x: number, y: number): void;
20
20
  } | (() => void) | ((qualifiedName: string) => string | null) | ((arg?: boolean | ScrollIntoViewOptions | undefined) => void) | (() => void) | (() => ElementInternals) | {
@@ -14,6 +14,7 @@
14
14
  * </example>
15
15
  *
16
16
  * @alias element.scrollIntoView
17
+ * @param {object|boolean=} scrollIntoViewOptions options for `Element.scrollIntoView()` (default: `{ block: 'start', inline: 'nearest' }`)
17
18
  * @uses protocol/execute
18
19
  * @type utility
19
20
  *
@@ -1 +1 @@
1
- {"version":3,"file":"scrollIntoView.d.ts","sourceRoot":"","sources":["../../../src/commands/element/scrollIntoView.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAA8B,cAAc,CACxC,IAAI,EAAE,WAAW,CAAC,OAAO,EACzB,OAAO,GAAE,qBAAqB,GAAG,OAA+C,iBA8BnF"}
1
+ {"version":3,"file":"scrollIntoView.d.ts","sourceRoot":"","sources":["../../../src/commands/element/scrollIntoView.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAA8B,cAAc,CACxC,IAAI,EAAE,WAAW,CAAC,OAAO,EACzB,OAAO,GAAE,qBAAqB,GAAG,OAA+C,iBA8BnF"}
@@ -15,6 +15,7 @@ import { getBrowserObject } from '../../utils/index.js';
15
15
  * </example>
16
16
  *
17
17
  * @alias element.scrollIntoView
18
+ * @param {object|boolean=} scrollIntoViewOptions options for `Element.scrollIntoView()` (default: `{ block: 'start', inline: 'nearest' }`)
18
19
  * @uses protocol/execute
19
20
  * @type utility
20
21
  *
@@ -1,8 +1,7 @@
1
1
  /**
2
2
  *
3
3
  * This wait command is your universal weapon if you want to wait on something. It expects a condition
4
- * and waits until that condition is fulfilled with a truthy value. If you use the WDIO testrunner the
5
- * commands within the condition are getting executed synchronously like in your test.
4
+ * and waits until that condition is fulfilled with a truthy value.
6
5
  *
7
6
  * :::info
8
7
  *
@@ -1 +1 @@
1
- {"version":3,"file":"waitUntil.d.ts","sourceRoot":"","sources":["../../../src/commands/element/waitUntil.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6CG;AACH,OAAO,SAAS,MAAM,yBAAyB,CAAA;AAC/C,eAAe,SAAS,CAAA"}
1
+ {"version":3,"file":"waitUntil.d.ts","sourceRoot":"","sources":["../../../src/commands/element/waitUntil.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4CG;AACH,OAAO,SAAS,MAAM,yBAAyB,CAAA;AAC/C,eAAe,SAAS,CAAA"}
@@ -1,8 +1,7 @@
1
1
  /**
2
2
  *
3
3
  * This wait command is your universal weapon if you want to wait on something. It expects a condition
4
- * and waits until that condition is fulfilled with a truthy value. If you use the WDIO testrunner the
5
- * commands within the condition are getting executed synchronously like in your test.
4
+ * and waits until that condition is fulfilled with a truthy value.
6
5
  *
7
6
  * :::info
8
7
  *
@@ -4,7 +4,7 @@
4
4
  * @param {String} property requested property
5
5
  * @return {String} the value of the property
6
6
  */
7
- export default function getProperty(element: HTMLElement, property: keyof HTMLElement): string | number | boolean | HTMLElement | Element | ChildNode | ParentNode | ((...nodes: (string | Node)[]) => void) | ((...nodes: (string | Node)[]) => void) | {
7
+ export default function getProperty(element: HTMLElement, property: keyof HTMLElement): string | number | boolean | HTMLElement | Element | EventTarget | ChildNode | ParentNode | ((...nodes: (string | Node)[]) => void) | ((...nodes: (string | Node)[]) => void) | {
8
8
  (options?: ScrollToOptions | undefined): void;
9
9
  (x: number, y: number): void;
10
10
  } | (() => void) | ((qualifiedName: string) => string | null) | ((arg?: boolean | ScrollIntoViewOptions | undefined) => void) | (() => void) | (() => ElementInternals) | {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "webdriverio",
3
3
  "description": "Next-gen browser and mobile automation test framework for Node.js",
4
- "version": "8.0.0-alpha.365+ea5d90e26",
4
+ "version": "8.0.0-alpha.412+a2bc7ec67",
5
5
  "homepage": "https://webdriver.io",
6
6
  "author": "Christian Bromann <mail@bromann.dev>",
7
7
  "license": "MIT",
@@ -69,18 +69,18 @@
69
69
  "dependencies": {
70
70
  "@types/aria-query": "^5.0.0",
71
71
  "@types/node": "^18.0.0",
72
- "@wdio/config": "8.0.0-alpha.365+ea5d90e26",
73
- "@wdio/logger": "8.0.0-alpha.365+ea5d90e26",
74
- "@wdio/protocols": "8.0.0-alpha.365+ea5d90e26",
75
- "@wdio/repl": "8.0.0-alpha.365+ea5d90e26",
76
- "@wdio/types": "8.0.0-alpha.365+ea5d90e26",
77
- "@wdio/utils": "8.0.0-alpha.365+ea5d90e26",
72
+ "@wdio/config": "8.0.0-alpha.412+a2bc7ec67",
73
+ "@wdio/logger": "8.0.0-alpha.412+a2bc7ec67",
74
+ "@wdio/protocols": "8.0.0-alpha.412+a2bc7ec67",
75
+ "@wdio/repl": "8.0.0-alpha.412+a2bc7ec67",
76
+ "@wdio/types": "8.0.0-alpha.412+a2bc7ec67",
77
+ "@wdio/utils": "8.0.0-alpha.412+a2bc7ec67",
78
78
  "archiver": "^5.0.0",
79
79
  "aria-query": "^5.0.0",
80
80
  "css-shorthand-properties": "^1.1.1",
81
81
  "css-value": "^0.0.1",
82
- "devtools": "8.0.0-alpha.365+ea5d90e26",
83
- "devtools-protocol": "^0.0.1048352",
82
+ "devtools": "8.0.0-alpha.412+a2bc7ec67",
83
+ "devtools-protocol": "^0.0.1056733",
84
84
  "fs-extra": "^10.0.0",
85
85
  "grapheme-splitter": "^1.0.2",
86
86
  "lodash.clonedeep": "^4.5.0",
@@ -88,12 +88,12 @@
88
88
  "lodash.isplainobject": "^4.0.6",
89
89
  "lodash.zip": "^4.2.0",
90
90
  "minimatch": "^5.0.0",
91
- "puppeteer-core": "18.0.4",
91
+ "puppeteer-core": "18.2.1",
92
92
  "query-selector-shadow-dom": "^1.0.0",
93
93
  "resq": "^1.9.1",
94
94
  "rgb2hex": "0.2.5",
95
95
  "serialize-error": "^8.0.0",
96
- "webdriver": "8.0.0-alpha.365+ea5d90e26"
96
+ "webdriver": "8.0.0-alpha.412+a2bc7ec67"
97
97
  },
98
- "gitHead": "ea5d90e263106af626e420bab7825bac4beb1dfe"
98
+ "gitHead": "a2bc7ec67e2a5fe000e539f44b0ea97f6e08ccbd"
99
99
  }