@wdio/utils 7.13.2 → 7.16.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/initialisePlugin.js +3 -3
- package/build/initialiseServices.js +2 -2
- package/build/monad.js +2 -2
- package/build/shim.d.ts +1 -0
- package/build/shim.d.ts.map +1 -1
- package/build/shim.js +11 -6
- package/build/test-framework/testFnWrapper.js +3 -3
- package/build/test-framework/testInterfaceWrapper.d.ts +1 -1
- package/build/test-framework/testInterfaceWrapper.d.ts.map +1 -1
- package/build/test-framework/testInterfaceWrapper.js +5 -5
- package/build/utils.js +2 -2
- package/package.json +4 -4
|
@@ -16,7 +16,7 @@ function initialisePlugin(name, type) {
|
|
|
16
16
|
* directly import packages that are scoped or start with an absolute path
|
|
17
17
|
*/
|
|
18
18
|
if (name[0] === '@' || path_1.default.isAbsolute(name)) {
|
|
19
|
-
const service = utils_1.safeRequire(name);
|
|
19
|
+
const service = (0, utils_1.safeRequire)(name);
|
|
20
20
|
if (service) {
|
|
21
21
|
return service;
|
|
22
22
|
}
|
|
@@ -27,14 +27,14 @@ function initialisePlugin(name, type) {
|
|
|
27
27
|
/**
|
|
28
28
|
* check for scoped version of plugin first (e.g. @wdio/sauce-service)
|
|
29
29
|
*/
|
|
30
|
-
const scopedPlugin = utils_1.safeRequire(`@wdio/${name.toLowerCase()}-${type}`);
|
|
30
|
+
const scopedPlugin = (0, utils_1.safeRequire)(`@wdio/${name.toLowerCase()}-${type}`);
|
|
31
31
|
if (scopedPlugin) {
|
|
32
32
|
return scopedPlugin;
|
|
33
33
|
}
|
|
34
34
|
/**
|
|
35
35
|
* check for old type of
|
|
36
36
|
*/
|
|
37
|
-
const plugin = utils_1.safeRequire(`wdio-${name.toLowerCase()}-${type}`);
|
|
37
|
+
const plugin = (0, utils_1.safeRequire)(`wdio-${name.toLowerCase()}-${type}`);
|
|
38
38
|
if (plugin) {
|
|
39
39
|
return plugin;
|
|
40
40
|
}
|
|
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
6
6
|
exports.initialiseWorkerService = exports.initialiseLauncherService = void 0;
|
|
7
7
|
const logger_1 = __importDefault(require("@wdio/logger"));
|
|
8
8
|
const initialisePlugin_1 = __importDefault(require("./initialisePlugin"));
|
|
9
|
-
const log = logger_1.default('@wdio/utils:initialiseServices');
|
|
9
|
+
const log = (0, logger_1.default)('@wdio/utils:initialiseServices');
|
|
10
10
|
/**
|
|
11
11
|
* Maps list of services of a config file into a list of actionable objects
|
|
12
12
|
* @param {Object} config config of running session
|
|
@@ -56,7 +56,7 @@ function initialiseServices(services) {
|
|
|
56
56
|
* ```
|
|
57
57
|
*/
|
|
58
58
|
log.debug(`initialise service "${serviceName}" as NPM package`);
|
|
59
|
-
const service = initialisePlugin_1.default(serviceName, 'service');
|
|
59
|
+
const service = (0, initialisePlugin_1.default)(serviceName, 'service');
|
|
60
60
|
initialisedServices.push([service, serviceConfig, serviceName]);
|
|
61
61
|
}
|
|
62
62
|
return initialisedServices;
|
package/build/monad.js
CHANGED
|
@@ -20,7 +20,7 @@ function WebDriver(options, modifier, propertiesObject = {}) {
|
|
|
20
20
|
const scopeType = SCOPE_TYPES[((_a = propertiesObject.scope) === null || _a === void 0 ? void 0 : _a.value) || 'browser'];
|
|
21
21
|
delete propertiesObject.scope;
|
|
22
22
|
const prototype = Object.create(scopeType.prototype);
|
|
23
|
-
const log = logger_1.default('webdriver');
|
|
23
|
+
const log = (0, logger_1.default)('webdriver');
|
|
24
24
|
const eventHandler = new events_1.EventEmitter();
|
|
25
25
|
const EVENTHANDLER_FUNCTIONS = Object.getPrototypeOf(eventHandler);
|
|
26
26
|
/**
|
|
@@ -138,7 +138,7 @@ function WebDriver(options, modifier, propertiesObject = {}) {
|
|
|
138
138
|
*/
|
|
139
139
|
unit.lift = function (name, func, proto, origCommand) {
|
|
140
140
|
(proto || prototype)[name] = function next(...args) {
|
|
141
|
-
log.info('COMMAND', utils_1.commandCallStructure(name, args));
|
|
141
|
+
log.info('COMMAND', (0, utils_1.commandCallStructure)(name, args));
|
|
142
142
|
/**
|
|
143
143
|
* set name of function for better error stack
|
|
144
144
|
*/
|
package/build/shim.d.ts
CHANGED
package/build/shim.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shim.d.ts","sourceRoot":"","sources":["../src/shim.ts"],"names":[],"mappings":"AAOA,QAAA,IAAI,kBAAkB,SAAQ,CAAA;AAC9B,QAAA,IAAI,OAAO,EAAE,CAAC,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,QAAQ,EAAE,UAAU,EAAE,GAAG,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,QAAQ,KAAK,OAAO,CAAA;AAEhI,UAAU,OAAO;IACb,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,MAAM,CAAA;CACnB;AAUD,OAAO,CAAC,MAAM,CAAC;IACX,IAAI,kBAAkB,EAAE,OAAO,CAAA;IAC/B,IAAI,OAAO,EAAE,GAAG,CAAA;
|
|
1
|
+
{"version":3,"file":"shim.d.ts","sourceRoot":"","sources":["../src/shim.ts"],"names":[],"mappings":"AAOA,QAAA,IAAI,kBAAkB,SAAQ,CAAA;AAC9B,QAAA,IAAI,OAAO,EAAE,CAAC,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,QAAQ,EAAE,UAAU,EAAE,GAAG,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,QAAQ,KAAK,OAAO,CAAA;AAEhI,UAAU,OAAO;IACb,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,MAAM,CAAA;CACnB;AAUD,OAAO,CAAC,MAAM,CAAC;IACX,IAAI,kBAAkB,EAAE,OAAO,CAAA;IAC/B,IAAI,OAAO,EAAE,GAAG,CAAA;IAChB,IAAI,WAAW,EAAE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
|
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
6
6
|
exports.runSync = exports.executeAsync = exports.executeSync = exports.hasWdioSyncSupport = exports.wrapCommand = exports.runFnInFiberContext = exports.executeHooksWithArgs = exports.switchSyncFlag = exports.asyncSpec = exports.runAsync = exports.expectAsyncShim = void 0;
|
|
7
7
|
const p_iteration_1 = __importDefault(require("p-iteration"));
|
|
8
8
|
const logger_1 = __importDefault(require("@wdio/logger"));
|
|
9
|
-
const log = logger_1.default('@wdio/utils:shim');
|
|
9
|
+
const log = (0, logger_1.default)('@wdio/utils:shim');
|
|
10
10
|
let inCommandHook = false;
|
|
11
11
|
let hasWdioSyncSupport = false;
|
|
12
12
|
exports.hasWdioSyncSupport = hasWdioSyncSupport;
|
|
@@ -293,12 +293,12 @@ async function executeSyncFn(fn, retries, args = []) {
|
|
|
293
293
|
}
|
|
294
294
|
return res;
|
|
295
295
|
}
|
|
296
|
-
catch (
|
|
296
|
+
catch (err) {
|
|
297
297
|
if (retries.limit > retries.attempts) {
|
|
298
298
|
retries.attempts++;
|
|
299
299
|
return await executeSyncFn.call(this, fn, retries, args);
|
|
300
300
|
}
|
|
301
|
-
return Promise.reject(
|
|
301
|
+
return Promise.reject(err);
|
|
302
302
|
}
|
|
303
303
|
}
|
|
304
304
|
/**
|
|
@@ -313,8 +313,10 @@ async function executeAsync(fn, retries, args = []) {
|
|
|
313
313
|
const isJasmine = global.jasmine && global.expectAsync;
|
|
314
314
|
const asyncSpecBefore = exports.asyncSpec;
|
|
315
315
|
this.wdioRetries = retries.attempts;
|
|
316
|
+
// @ts-ignore
|
|
316
317
|
expectSync = global.expect;
|
|
317
318
|
if (isJasmine) {
|
|
319
|
+
// @ts-ignore
|
|
318
320
|
global.expect = expectAsyncShim;
|
|
319
321
|
}
|
|
320
322
|
try {
|
|
@@ -322,22 +324,25 @@ async function executeAsync(fn, retries, args = []) {
|
|
|
322
324
|
exports.asyncSpec = true;
|
|
323
325
|
const result = fn.apply(this, args);
|
|
324
326
|
if (result && typeof result.finally === 'function') {
|
|
325
|
-
result
|
|
327
|
+
result
|
|
328
|
+
.finally(() => (exports.asyncSpec = asyncSpecBefore))
|
|
329
|
+
.catch((err) => err);
|
|
326
330
|
}
|
|
327
331
|
else {
|
|
328
332
|
exports.asyncSpec = asyncSpecBefore;
|
|
329
333
|
}
|
|
330
334
|
return await result;
|
|
331
335
|
}
|
|
332
|
-
catch (
|
|
336
|
+
catch (err) {
|
|
333
337
|
if (retries.limit > retries.attempts) {
|
|
334
338
|
retries.attempts++;
|
|
335
339
|
return await executeAsync.call(this, fn, retries, args);
|
|
336
340
|
}
|
|
337
|
-
throw
|
|
341
|
+
throw err;
|
|
338
342
|
}
|
|
339
343
|
finally {
|
|
340
344
|
if (isJasmine) {
|
|
345
|
+
// @ts-ignore
|
|
341
346
|
global.expect = expectSync;
|
|
342
347
|
}
|
|
343
348
|
}
|
|
@@ -34,14 +34,14 @@ exports.testFnWrapper = testFnWrapper;
|
|
|
34
34
|
const testFrameworkFnWrapper = async function ({ executeHooksWithArgs, executeAsync, runSync }, type, { specFn, specFnArgs }, { beforeFn, beforeFnArgs }, { afterFn, afterFnArgs }, cid, repeatTest = 0) {
|
|
35
35
|
const retries = { attempts: 0, limit: repeatTest };
|
|
36
36
|
const beforeArgs = beforeFnArgs(this);
|
|
37
|
-
await errorHandler_1.logHookError(`Before${type}`, await executeHooksWithArgs(`before${type}`, beforeFn, beforeArgs), cid);
|
|
37
|
+
await (0, errorHandler_1.logHookError)(`Before${type}`, await executeHooksWithArgs(`before${type}`, beforeFn, beforeArgs), cid);
|
|
38
38
|
let promise;
|
|
39
39
|
let result;
|
|
40
40
|
let error;
|
|
41
41
|
/**
|
|
42
42
|
* user wants handle async command using promises, no need to wrap in fiber context
|
|
43
43
|
*/
|
|
44
|
-
if (utils_1.isFunctionAsync(specFn) || !runSync) {
|
|
44
|
+
if ((0, utils_1.isFunctionAsync)(specFn) || !runSync) {
|
|
45
45
|
promise = executeAsync.call(this, specFn, retries, specFnArgs);
|
|
46
46
|
}
|
|
47
47
|
else {
|
|
@@ -71,7 +71,7 @@ const testFrameworkFnWrapper = async function ({ executeHooksWithArgs, executeAs
|
|
|
71
71
|
duration,
|
|
72
72
|
passed: !error
|
|
73
73
|
});
|
|
74
|
-
await errorHandler_1.logHookError(`After${type}`, await executeHooksWithArgs(`after${type}`, afterFn, [...afterArgs]), cid);
|
|
74
|
+
await (0, errorHandler_1.logHookError)(`After${type}`, await executeHooksWithArgs(`after${type}`, afterFn, [...afterArgs]), cid);
|
|
75
75
|
if (error && !error.matcherName) {
|
|
76
76
|
throw error;
|
|
77
77
|
}
|
|
@@ -64,5 +64,5 @@ export declare const wrapTestFunction: (this: unknown, origFn: Function, isSpec:
|
|
|
64
64
|
* @param {String} cid cid
|
|
65
65
|
* @param {Object} scope the scope to run command from, defaults to global
|
|
66
66
|
*/
|
|
67
|
-
export declare const runTestInFiberContext: (this: unknown, isSpec: boolean, beforeFn: Function | Function[], beforeArgsFn: HookFnArgs<unknown>, afterFn: Function | Function[], afterArgsFn: HookFnArgs<unknown>, fnName: string, cid: string, scope?:
|
|
67
|
+
export declare const runTestInFiberContext: (this: unknown, isSpec: boolean, beforeFn: Function | Function[], beforeArgsFn: HookFnArgs<unknown>, afterFn: Function | Function[], afterArgsFn: HookFnArgs<unknown>, fnName: string, cid: string, scope?: typeof globalThis) => void;
|
|
68
68
|
//# sourceMappingURL=testInterfaceWrapper.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"testInterfaceWrapper.d.ts","sourceRoot":"","sources":["../../src/test-framework/testInterfaceWrapper.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAKH,OAAO,KAAK,EACR,UAAU,EAIV,aAAa,EAChB,MAAM,SAAS,CAAA;AAIhB;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,OAAO,SACV,OAAO,UACL,QAAQ,UACR,QAAQ,YACN,QAAQ,GAAG,QAAQ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MAAM,cACC,MAAM,WACT,MAAM,QAgClB,CAAA;AAED;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,OAAO,SACV,OAAO,aACF,MAAM,UACT,QAAQ,UACR,QAAQ,YACN,QAAQ,GAAG,QAAQ,EAAE,gBACjB,WAAW,OAAO,CAAC,WACxB,QAAQ,GAAG,QAAQ,EAAE,eACjB,WAAW,OAAO,CAAC,OAC3B,MAAM,cACC,MAAM,WACT,MAAM,QAgClB,CAAA;AAED;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,gBAAgB,SACnB,OAAO,UACL,QAAQ,UACR,OAAO,YACL,QAAQ,GAAG,QAAQ,EAAE,gBACjB,WAAW,OAAO,CAAC,WACxB,QAAQ,GAAG,QAAQ,EAAE,eACjB,WAAW,OAAO,CAAC,OAC3B,MAAM,wBAEwB,aAAa,QAgEnD,CAAA;AAED;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,qBAAqB,SACxB,OAAO,UACL,OAAO,YACL,QAAQ,GAAG,QAAQ,EAAE,gBACjB,WAAW,OAAO,CAAC,WACxB,QAAQ,GAAG,QAAQ,EAAE,eACjB,WAAW,OAAO,CAAC,UACxB,MAAM,OACT,MAAM,oCAcd,CAAA"}
|
|
@@ -29,7 +29,7 @@ const runHook = function (hookFn, origFn, beforeFn, beforeFnArgs, afterFn, after
|
|
|
29
29
|
return origFn(function (...hookFnArgs) {
|
|
30
30
|
return testFnWrapper_1.testFnWrapper.call(this, 'Hook', {
|
|
31
31
|
specFn: hookFn,
|
|
32
|
-
specFnArgs: utils_1.filterSpecArgs(hookFnArgs)
|
|
32
|
+
specFnArgs: (0, utils_1.filterSpecArgs)(hookFnArgs)
|
|
33
33
|
}, {
|
|
34
34
|
beforeFn,
|
|
35
35
|
beforeFnArgs
|
|
@@ -58,7 +58,7 @@ const runSpec = function (specTitle, specFn, origFn, beforeFn, beforeFnArgs, aft
|
|
|
58
58
|
return origFn(specTitle, function (...specFnArgs) {
|
|
59
59
|
return testFnWrapper_1.testFnWrapper.call(this, 'Test', {
|
|
60
60
|
specFn,
|
|
61
|
-
specFnArgs: utils_1.filterSpecArgs(specFnArgs)
|
|
61
|
+
specFnArgs: (0, utils_1.filterSpecArgs)(specFnArgs)
|
|
62
62
|
}, {
|
|
63
63
|
beforeFn,
|
|
64
64
|
beforeFnArgs
|
|
@@ -114,14 +114,14 @@ const wrapTestFunction = function (origFn, isSpec, beforeFn, beforeArgsFn, after
|
|
|
114
114
|
const specTitle = specArguments[0];
|
|
115
115
|
if (isSpec) {
|
|
116
116
|
if (specFn) {
|
|
117
|
-
return exports.runSpec(specTitle, specFn, origFn, beforeFn, beforeArgsFn, afterFn, afterArgsFn, cid, retryCnt, timeout);
|
|
117
|
+
return (0, exports.runSpec)(specTitle, specFn, origFn, beforeFn, beforeArgsFn, afterFn, afterArgsFn, cid, retryCnt, timeout);
|
|
118
118
|
}
|
|
119
119
|
/**
|
|
120
120
|
* if specFn is undefined we are dealing with a pending function
|
|
121
121
|
*/
|
|
122
122
|
return origFn(specTitle);
|
|
123
123
|
}
|
|
124
|
-
return exports.runHook(specFn, origFn, beforeFn, beforeArgsFn, afterFn, afterArgsFn, cid, retryCnt, timeout);
|
|
124
|
+
return (0, exports.runHook)(specFn, origFn, beforeFn, beforeArgsFn, afterFn, afterArgsFn, cid, retryCnt, timeout);
|
|
125
125
|
};
|
|
126
126
|
};
|
|
127
127
|
exports.wrapTestFunction = wrapTestFunction;
|
|
@@ -141,7 +141,7 @@ exports.wrapTestFunction = wrapTestFunction;
|
|
|
141
141
|
*/
|
|
142
142
|
const runTestInFiberContext = function (isSpec, beforeFn, beforeArgsFn, afterFn, afterArgsFn, fnName, cid, scope = global) {
|
|
143
143
|
const origFn = scope[fnName];
|
|
144
|
-
scope[fnName] = exports.wrapTestFunction(origFn, isSpec, beforeFn, beforeArgsFn, afterFn, afterArgsFn, cid);
|
|
144
|
+
scope[fnName] = (0, exports.wrapTestFunction)(origFn, isSpec, beforeFn, beforeArgsFn, afterFn, afterArgsFn, cid);
|
|
145
145
|
addMochaCommands(origFn, scope[fnName]);
|
|
146
146
|
};
|
|
147
147
|
exports.runTestInFiberContext = runTestInFiberContext;
|
package/build/utils.js
CHANGED
|
@@ -177,7 +177,7 @@ function safeRequire(name) {
|
|
|
177
177
|
requirePath = require.resolve(name);
|
|
178
178
|
}
|
|
179
179
|
}
|
|
180
|
-
catch (
|
|
180
|
+
catch (err) {
|
|
181
181
|
return null;
|
|
182
182
|
}
|
|
183
183
|
try {
|
|
@@ -238,7 +238,7 @@ const canAccess = (file) => {
|
|
|
238
238
|
fs_1.default.accessSync(file);
|
|
239
239
|
return true;
|
|
240
240
|
}
|
|
241
|
-
catch (
|
|
241
|
+
catch (err) {
|
|
242
242
|
return false;
|
|
243
243
|
}
|
|
244
244
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wdio/utils",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.16.3",
|
|
4
4
|
"description": "A WDIO helper utility to provide several utility functions used across the project.",
|
|
5
5
|
"author": "Christian Bromann <christian@saucelabs.com>",
|
|
6
6
|
"homepage": "https://github.com/webdriverio/webdriverio/tree/main/packages/wdio-utils",
|
|
@@ -23,13 +23,13 @@
|
|
|
23
23
|
"url": "https://github.com/webdriverio/webdriverio/issues"
|
|
24
24
|
},
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@wdio/logger": "7.
|
|
27
|
-
"@wdio/types": "7.
|
|
26
|
+
"@wdio/logger": "7.16.0",
|
|
27
|
+
"@wdio/types": "7.16.3",
|
|
28
28
|
"p-iteration": "^1.1.8"
|
|
29
29
|
},
|
|
30
30
|
"publishConfig": {
|
|
31
31
|
"access": "public"
|
|
32
32
|
},
|
|
33
33
|
"types": "./build/index.d.ts",
|
|
34
|
-
"gitHead": "
|
|
34
|
+
"gitHead": "23e2af933060e829f03d7518089c377571c654e3"
|
|
35
35
|
}
|