@wdio/utils 9.4.2 → 9.4.3
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.
- package/build/envDetector.d.ts +3 -3
- package/build/envDetector.d.ts.map +1 -1
- package/build/index.js +3 -10
- package/build/node/manager.d.ts.map +1 -1
- package/build/node.js +2 -1
- package/package.json +3 -3
package/build/envDetector.d.ts
CHANGED
|
@@ -6,11 +6,11 @@ import type { Capabilities } from '@wdio/types';
|
|
|
6
6
|
*/
|
|
7
7
|
export declare function isW3C(capabilities?: WebdriverIO.Capabilities): boolean;
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
10
|
-
* @param {object} capabilities session capabilities
|
|
9
|
+
* Detects if session has support for WebDriver Bidi.
|
|
10
|
+
* @param {object} capabilities resolved session capabilities send back from the driver
|
|
11
11
|
* @return {Boolean} true if session has WebDriver Bidi support
|
|
12
12
|
*/
|
|
13
|
-
export declare function isBidi(
|
|
13
|
+
export declare function isBidi(capabilities: WebdriverIO.Capabilities): boolean;
|
|
14
14
|
/**
|
|
15
15
|
* returns information about the environment before the session is created
|
|
16
16
|
* @param {Object} capabilities caps provided by user
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"envDetector.d.ts","sourceRoot":"","sources":["../src/envDetector.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;
|
|
1
|
+
{"version":3,"file":"envDetector.d.ts","sourceRoot":"","sources":["../src/envDetector.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAS/C;;;;GAIG;AACH,wBAAgB,KAAK,CAAC,YAAY,CAAC,EAAE,WAAW,CAAC,YAAY,WAqC5D;AAgKD;;;;GAIG;AACH,wBAAgB,MAAM,CAAC,YAAY,EAAE,WAAW,CAAC,YAAY,WAM5D;AAoCD;;;;GAIG;AACH,wBAAgB,+BAA+B,CAAC,YAAY,EAAE,WAAW,CAAC,YAAY;;;;;;;;;EAWrF;AAED;;;;;GAKG;AACH,wBAAgB,0BAA0B,CAAC,EACvC,YAAY,EACZ,qBAAqB,EACxB,EAAE;IACC,YAAY,EAAE,WAAW,CAAC,YAAY,CAAC;IACvC,qBAAqB,EAAE,YAAY,CAAC,+BAA+B,CAAA;CACtE;;;;;;;;;;;EAaA"}
|
package/build/index.js
CHANGED
|
@@ -1227,7 +1227,6 @@ function addMochaCommands(origFn, newFn) {
|
|
|
1227
1227
|
}
|
|
1228
1228
|
|
|
1229
1229
|
// src/envDetector.ts
|
|
1230
|
-
var APPIUM_CAPABILITY_PREFIX = "appium:";
|
|
1231
1230
|
var MOBILE_BROWSER_NAMES = ["ipad", "iphone", "android"];
|
|
1232
1231
|
var MOBILE_CAPABILITIES = [
|
|
1233
1232
|
"appium-version",
|
|
@@ -1333,16 +1332,10 @@ function isSauce(capabilities) {
|
|
|
1333
1332
|
caps["sauce:options"] && caps["sauce:options"].extendedDebugging
|
|
1334
1333
|
);
|
|
1335
1334
|
}
|
|
1336
|
-
function
|
|
1337
|
-
return capabilityName.startsWith(APPIUM_CAPABILITY_PREFIX);
|
|
1338
|
-
}
|
|
1339
|
-
function isBidi(requestedCapabilities, capabilities) {
|
|
1335
|
+
function isBidi(capabilities) {
|
|
1340
1336
|
if (!capabilities) {
|
|
1341
1337
|
return false;
|
|
1342
1338
|
}
|
|
1343
|
-
if (Object.keys(requestedCapabilities).some(isAppiumCapability2)) {
|
|
1344
|
-
return false;
|
|
1345
|
-
}
|
|
1346
1339
|
return typeof capabilities.webSocketUrl === "string";
|
|
1347
1340
|
}
|
|
1348
1341
|
function isSeleniumStandalone(capabilities) {
|
|
@@ -1374,7 +1367,7 @@ function capabilitiesEnvironmentDetector(capabilities) {
|
|
|
1374
1367
|
isIOS: isIOS(capabilities),
|
|
1375
1368
|
isAndroid: isAndroid(capabilities),
|
|
1376
1369
|
isSauce: isSauce(capabilities),
|
|
1377
|
-
isBidi: isBidi(
|
|
1370
|
+
isBidi: isBidi(capabilities),
|
|
1378
1371
|
isChromium: isChromium(capabilities)
|
|
1379
1372
|
};
|
|
1380
1373
|
}
|
|
@@ -1391,7 +1384,7 @@ function sessionEnvironmentDetector({
|
|
|
1391
1384
|
isAndroid: isAndroid(capabilities),
|
|
1392
1385
|
isSauce: isSauce(requestedCapabilities),
|
|
1393
1386
|
isSeleniumStandalone: isSeleniumStandalone(capabilities),
|
|
1394
|
-
isBidi: isBidi(
|
|
1387
|
+
isBidi: isBidi(capabilities),
|
|
1395
1388
|
isChromium: isChromium(capabilities)
|
|
1396
1389
|
};
|
|
1397
1390
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"manager.d.ts","sourceRoot":"","sources":["../../src/node/manager.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;
|
|
1
|
+
{"version":3,"file":"manager.d.ts","sourceRoot":"","sources":["../../src/node/manager.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AA4GxD,wBAAsB,WAAW,CAAE,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE,cAAc,CAAC,EAAE,IAAI,EAAE,YAAY,CAAC,sBAAsB,kCAqB7H;AAED,wBAAgB,YAAY,CAAE,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE,cAAc,CAAC,EAAE,IAAI,EAAE,YAAY,CAAC,sBAAsB,kCAYxH"}
|
package/build/node.js
CHANGED
|
@@ -388,6 +388,7 @@ If you like to run a local browser session make sure to pick from one of the fol
|
|
|
388
388
|
import logger3 from "@wdio/logger";
|
|
389
389
|
var log3 = logger3("@wdio/utils");
|
|
390
390
|
var UNDEFINED_BROWSER_VERSION = null;
|
|
391
|
+
var firefoxChannels = ["stable", "latest"];
|
|
391
392
|
function mapCapabilities(options, caps, task, taskItemLabel) {
|
|
392
393
|
const capabilitiesToRequireSetup = (Array.isArray(caps) ? caps.map((cap) => {
|
|
393
394
|
const w3cCaps = cap;
|
|
@@ -450,7 +451,7 @@ async function setupDriver(options, caps) {
|
|
|
450
451
|
if (isEdge(cap.browserName)) {
|
|
451
452
|
return setupEdgedriver(cacheDir, cap.browserVersion);
|
|
452
453
|
} else if (isFirefox(cap.browserName)) {
|
|
453
|
-
const version = cap.browserVersion
|
|
454
|
+
const version = firefoxChannels.includes(cap.browserVersion ?? "") ? void 0 : cap.browserVersion;
|
|
454
455
|
return setupGeckodriver(cacheDir, version);
|
|
455
456
|
} else if (isChrome(cap.browserName)) {
|
|
456
457
|
return setupChromedriver(cacheDir, cap.browserVersion);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wdio/utils",
|
|
3
|
-
"version": "9.4.
|
|
3
|
+
"version": "9.4.3",
|
|
4
4
|
"description": "A WDIO helper utility to provide several utility functions used across the project.",
|
|
5
5
|
"author": "Christian Bromann <mail@bromann.dev>",
|
|
6
6
|
"homepage": "https://github.com/webdriverio/webdriverio/tree/main/packages/wdio-utils",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"@puppeteer/browsers": "^2.2.0",
|
|
40
40
|
"@wdio/logger": "9.1.3",
|
|
41
|
-
"@wdio/types": "9.4.
|
|
41
|
+
"@wdio/types": "9.4.3",
|
|
42
42
|
"decamelize": "^6.0.0",
|
|
43
43
|
"deepmerge-ts": "^7.0.3",
|
|
44
44
|
"edgedriver": "^6.1.1",
|
|
@@ -53,5 +53,5 @@
|
|
|
53
53
|
"publishConfig": {
|
|
54
54
|
"access": "public"
|
|
55
55
|
},
|
|
56
|
-
"gitHead": "
|
|
56
|
+
"gitHead": "8ee63eaefd86cf06eea832bb8d4c1920e9cc4e55"
|
|
57
57
|
}
|