1 | import type { Capabilities, Options, Services } from '@wdio/types';
|
2 | import { ModuleRequireService } from '../utils';
|
3 | declare type Spec = string | string[];
|
4 | interface TestrunnerOptionsWithParameters extends Omit<Options.Testrunner, 'capabilities'> {
|
5 | watch?: boolean;
|
6 | spec?: string[];
|
7 | suite?: string[];
|
8 | capabilities?: Capabilities.RemoteCapabilities;
|
9 | }
|
10 | interface MergeConfig extends Omit<Partial<TestrunnerOptionsWithParameters>, 'specs' | 'exclude'> {
|
11 | specs?: Spec[];
|
12 | exclude?: string[];
|
13 | }
|
14 | interface CurrentPathFinder {
|
15 | getcwd(): string;
|
16 | }
|
17 | interface LoadConfigFile {
|
18 | loadFile<T>(path: string): T;
|
19 | }
|
20 | interface IsFileDetector {
|
21 | isFile(path: string): boolean;
|
22 | }
|
23 | interface DeterminesAbsolutePath {
|
24 | ensureAbsolutePath(path: string): string;
|
25 | }
|
26 | interface Globber {
|
27 | glob(pattern: string): string[];
|
28 | }
|
29 | export interface PathService extends CurrentPathFinder, LoadConfigFile, IsFileDetector, Globber, DeterminesAbsolutePath {
|
30 | }
|
31 | export default class ConfigParser {
|
32 | private _config;
|
33 | private _capabilities;
|
34 | private _pathService;
|
35 | private _moduleRequireService;
|
36 | constructor(pathService?: PathService, moduleRequireService?: ModuleRequireService);
|
37 | autoCompile(): void;
|
38 | /**
|
39 | * merges config file with default values
|
40 | * @param {String} filename path of file relative to current directory
|
41 | */
|
42 | addConfigFile(filename: string): void;
|
43 | |
44 |
|
45 |
|
46 |
|
47 | merge(object?: MergeConfig): void;
|
48 | |
49 |
|
50 |
|
51 |
|
52 | addService(service: Services.Hooks): void;
|
53 | |
54 |
|
55 |
|
56 | getSpecs(capSpecs?: string[], capExclude?: string[]): Spec[];
|
57 | |
58 |
|
59 |
|
60 |
|
61 |
|
62 |
|
63 |
|
64 |
|
65 |
|
66 | setFilePathToFilterOptions(cliArgFileList: string[], config: Spec[]): string[];
|
67 | |
68 |
|
69 |
|
70 | getConfig(): Required<Options.Testrunner>;
|
71 | |
72 |
|
73 |
|
74 | getCapabilities(i?: number): Capabilities.DesiredCapabilities | Capabilities.W3CCapabilities | Capabilities.RemoteCapabilities;
|
75 | |
76 |
|
77 |
|
78 |
|
79 |
|
80 |
|
81 |
|
82 |
|
83 |
|
84 | static getFilePaths(patterns: Spec[], omitWarnings?: boolean, findAndGlob?: CurrentPathFinder & Globber & DeterminesAbsolutePath, hierarchyDepth?: number): Spec[];
|
85 | |
86 |
|
87 |
|
88 |
|
89 |
|
90 |
|
91 |
|
92 | filterSpecs(specs: Spec[], exclude: string[]): Spec[];
|
93 | }
|
94 | export {};
|
95 |
|
\ | No newline at end of file |