@wdio/config 8.0.0-alpha.565 → 8.0.0-alpha.577
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/constants.d.ts.map +1 -1
- package/build/constants.js +0 -3
- package/build/lib/ConfigParser.js +1 -1
- package/build/utils.d.ts +1 -2
- package/build/utils.d.ts.map +1 -1
- package/build/utils.js +5 -24
- package/package.json +7 -6
package/build/constants.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAA;AAKpD,eAAO,MAAM,eAAe,EAAE,MAAM,IAAI,CAAC,OAAO,CAAC,UAAU,EAAE,cAAc,
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAA;AAKpD,eAAO,MAAM,eAAe,EAAE,MAAM,IAAI,CAAC,OAAO,CAAC,UAAU,EAAE,cAAc,CA6EzE,CAAA;AAEF,eAAO,MAAM,eAAe,EAAE,CAAC,MAAM,QAAQ,CAAC,KAAK,CAAC,EAMnD,CAAA;AAED,eAAO,MAAM,yBAAyB,UAErC,CAAA;AAED,eAAO,MAAM,sBAAsB,QAIlC,CAAA"}
|
package/build/constants.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import path from 'node:path';
|
|
2
|
-
import { deepmerge } from 'deepmerge-ts';
|
|
3
2
|
import logger from '@wdio/logger';
|
|
3
|
+
import { deepmerge } from 'deepmerge-ts';
|
|
4
4
|
import RequireLibrary from './RequireLibrary.js';
|
|
5
5
|
import FileSystemPathService from './FileSystemPathService.js';
|
|
6
6
|
import { removeLineNumbers, isCucumberFeatureWithLineNumber, validObjectOrArray, loadAutoCompilers, makeRelativeToCWD } from '../utils.js';
|
package/build/utils.d.ts
CHANGED
|
@@ -23,8 +23,7 @@ export declare function isCloudCapability(caps: Capabilities.Capabilities): bool
|
|
|
23
23
|
*/
|
|
24
24
|
export declare function validateConfig<T>(defaults: Options.Definition<T>, options: T, keysToKeep?: (keyof T)[]): T;
|
|
25
25
|
export declare function loadAutoCompilers(autoCompileConfig: Options.AutoCompileConfig, requireService: ModuleImportService): Promise<boolean | undefined>;
|
|
26
|
-
export declare function
|
|
27
|
-
export declare function loadTypeScriptCompiler(tsNodeOpts: any, tsConfigPathsOpts: Options.TSConfigPathsOptions | undefined, requireService: ModuleImportService): Promise<boolean>;
|
|
26
|
+
export declare function loadTypeScriptCompiler(): Promise<boolean>;
|
|
28
27
|
export declare function loadBabelCompiler(babelOpts: Record<string, any> | undefined, requireService: ModuleImportService): Promise<boolean>;
|
|
29
28
|
export declare function makeRelativeToCWD(files?: (string | string[])[]): (string | string[])[];
|
|
30
29
|
//# sourceMappingURL=utils.d.ts.map
|
package/build/utils.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../src/utils.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,aAAa,CAAA;AAExD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAA;AAIrD,eAAO,MAAM,kBAAkB,WAAY,GAAG,6BACoB,CAAA;AAElE;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,MAAM,UAMjD;AAED;;;;GAIG;AACH,wBAAgB,+BAA+B,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,EAAE,WAGtE;AAED,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,YAAY,CAAC,YAAY,WAEhE;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,CAAC,EAAE,QAAQ,EAAE,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,UAAU,cAAoB,KA+C5G;AAED,wBAAsB,iBAAiB,CAAC,iBAAiB,EAAE,OAAO,CAAC,iBAAiB,EAAE,cAAc,EAAE,mBAAmB,
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../src/utils.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,aAAa,CAAA;AAExD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAA;AAIrD,eAAO,MAAM,kBAAkB,WAAY,GAAG,6BACoB,CAAA;AAElE;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,MAAM,UAMjD;AAED;;;;GAIG;AACH,wBAAgB,+BAA+B,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,EAAE,WAGtE;AAED,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,YAAY,CAAC,YAAY,WAEhE;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,CAAC,EAAE,QAAQ,EAAE,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,UAAU,cAAoB,KA+C5G;AAED,wBAAsB,iBAAiB,CAAC,iBAAiB,EAAE,OAAO,CAAC,iBAAiB,EAAE,cAAc,EAAE,mBAAmB,gCAWxH;AAED,wBAAsB,sBAAsB,qBAO3C;AAED,wBAAsB,iBAAiB,CAAE,SAAS,iCAA0B,EAAE,cAAc,EAAE,mBAAmB,oBAehH;AAED,wBAAgB,iBAAiB,CAAE,KAAK,GAAE,CAAC,MAAM,GAAG,MAAM,EAAE,CAAC,EAAO,GAAG,CAAC,MAAM,GAAG,MAAM,EAAE,CAAC,EAAE,CAa3F"}
|
package/build/utils.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import path from 'node:path';
|
|
2
|
-
import { canAccess } from '@wdio/utils';
|
|
3
2
|
import logger from '@wdio/logger';
|
|
3
|
+
import { resolve } from 'import-meta-resolve';
|
|
4
4
|
const log = logger('@wdio/config:utils');
|
|
5
5
|
export const validObjectOrArray = (object) => (Array.isArray(object) && object.length > 0) ||
|
|
6
6
|
(typeof object === 'object' && Object.keys(object).length > 0);
|
|
@@ -78,31 +78,12 @@ export function validateConfig(defaults, options, keysToKeep = []) {
|
|
|
78
78
|
}
|
|
79
79
|
export async function loadAutoCompilers(autoCompileConfig, requireService) {
|
|
80
80
|
return (autoCompileConfig.autoCompile &&
|
|
81
|
-
(await loadTypeScriptCompiler(
|
|
82
|
-
|
|
83
|
-
await loadBabelCompiler(autoCompileConfig.babelOpts, requireService)));
|
|
81
|
+
(await loadTypeScriptCompiler() ||
|
|
82
|
+
await loadBabelCompiler(autoCompileConfig.babelOpts, requireService)));
|
|
84
83
|
}
|
|
85
|
-
export function
|
|
86
|
-
/**
|
|
87
|
-
* Checks tsconfig.json path, throws error if it doesn't exist
|
|
88
|
-
*/
|
|
89
|
-
if (tsNodeOpts?.project) {
|
|
90
|
-
const tsconfigPath = path.resolve(tsNodeOpts.project);
|
|
91
|
-
if (!canAccess(tsconfigPath)) {
|
|
92
|
-
throw new Error('Provided tsconfig file path in wdio config is incorrect. Is it correctly set in wdio config ?');
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
export async function loadTypeScriptCompiler(tsNodeOpts = {}, tsConfigPathsOpts, requireService) {
|
|
84
|
+
export async function loadTypeScriptCompiler() {
|
|
97
85
|
try {
|
|
98
|
-
|
|
99
|
-
(await requireService.import('ts-node')).register({ ...tsNodeOpts, esm: 1 });
|
|
100
|
-
log.debug('Found \'ts-node\' package, auto-compiling TypeScript files');
|
|
101
|
-
if (tsConfigPathsOpts) {
|
|
102
|
-
log.debug('Found \'tsconfig-paths\' options, register paths');
|
|
103
|
-
const tsConfigPaths = await requireService.import('tsconfig-paths');
|
|
104
|
-
tsConfigPaths.register(tsConfigPathsOpts);
|
|
105
|
-
}
|
|
86
|
+
await resolve('ts-node', import.meta.url);
|
|
106
87
|
return true;
|
|
107
88
|
}
|
|
108
89
|
catch (err) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wdio/config",
|
|
3
|
-
"version": "8.0.0-alpha.
|
|
3
|
+
"version": "8.0.0-alpha.577+73cd77ef7",
|
|
4
4
|
"description": "A helper utility to parse and validate WebdriverIO options",
|
|
5
5
|
"author": "Christian Bromann <mail@bromann.dev>",
|
|
6
6
|
"homepage": "https://github.com/webdriverio/webdriverio/tree/main/packages/wdio-config",
|
|
@@ -26,11 +26,12 @@
|
|
|
26
26
|
"url": "https://github.com/webdriverio/webdriverio/issues"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@wdio/logger": "8.0.0-alpha.
|
|
30
|
-
"@wdio/types": "8.0.0-alpha.
|
|
31
|
-
"@wdio/utils": "8.0.0-alpha.
|
|
29
|
+
"@wdio/logger": "8.0.0-alpha.577+73cd77ef7",
|
|
30
|
+
"@wdio/types": "8.0.0-alpha.577+73cd77ef7",
|
|
31
|
+
"@wdio/utils": "8.0.0-alpha.577+73cd77ef7",
|
|
32
32
|
"deepmerge-ts": "^4.2.2",
|
|
33
|
-
"glob": "^8.0.3"
|
|
33
|
+
"glob": "^8.0.3",
|
|
34
|
+
"import-meta-resolve": "^2.1.0"
|
|
34
35
|
},
|
|
35
36
|
"publishConfig": {
|
|
36
37
|
"access": "public"
|
|
@@ -39,5 +40,5 @@
|
|
|
39
40
|
"minimatch": "^5.0.0",
|
|
40
41
|
"tsconfig-paths": "^4.1.0"
|
|
41
42
|
},
|
|
42
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "73cd77ef7887819c56dc98932a0c34e8af10b64a"
|
|
43
44
|
}
|