]>
Commit | Line | Data |
---|---|---|
1 | export const config = { | |
2 | // | |
3 | // ==================== | |
4 | // Runner Configuration | |
5 | // ==================== | |
6 | // | |
7 | // | |
8 | // ================== | |
9 | // Specify Test Files | |
10 | // ================== | |
11 | // Define which test specs should run. The pattern is relative to the directory | |
12 | // from which `wdio` was called. | |
13 | // | |
14 | // The specs are defined as an array of spec files (optionally using wildcards | |
15 | // that will be expanded). The test for each spec file will be run in a separate | |
16 | // worker process. In order to have a group of spec files run in the same worker | |
17 | // process simply enclose them in an array within the specs array. | |
18 | // | |
19 | // If you are calling `wdio` from an NPM script (see https://docs.npmjs.com/cli/run-script), | |
20 | // then the current working directory is where your `package.json` resides, so `wdio` | |
21 | // will be called from there. | |
22 | // | |
23 | specs: [ | |
24 | './src/suites-all/*.e2e-spec.ts', | |
25 | './src/suites-local/*.e2e-spec.ts' | |
26 | ], | |
27 | // Patterns to exclude. | |
28 | exclude: [ | |
29 | // 'path/to/excluded/files' | |
30 | ], | |
31 | // | |
32 | // =================== | |
33 | // Test Configurations | |
34 | // =================== | |
35 | // Define all options that are relevant for the WebdriverIO instance here | |
36 | // | |
37 | // Level of logging verbosity: trace | debug | info | warn | error | silent | |
38 | logLevel: 'info', | |
39 | // | |
40 | // Set specific log levels per logger | |
41 | // loggers: | |
42 | // - webdriver, webdriverio | |
43 | // - @wdio/browserstack-service, @wdio/devtools-service, @wdio/sauce-service | |
44 | // - @wdio/mocha-framework, @wdio/jasmine-framework | |
45 | // - @wdio/local-runner | |
46 | // - @wdio/sumologic-reporter | |
47 | // - @wdio/cli, @wdio/config, @wdio/utils | |
48 | // Level of logging verbosity: trace | debug | info | warn | error | silent | |
49 | // logLevels: { | |
50 | // webdriver: 'info', | |
51 | // '@wdio/appium-service': 'info' | |
52 | // }, | |
53 | // | |
54 | // If you only want to run your tests until a specific amount of tests have failed use | |
55 | // bail (default is 0 - don't bail, run all tests). | |
56 | bail: 0, | |
57 | // | |
58 | // Set a base URL in order to shorten url command calls. If your `url` parameter starts | |
59 | // with `/`, the base url gets prepended, not including the path portion of your baseUrl. | |
60 | // If your `url` parameter starts without a scheme or `/` (like `some/path`), the base url | |
61 | // gets prepended directly. | |
62 | baseUrl: 'http://localhost:9001', | |
63 | // | |
64 | // Default timeout for all waitFor* commands. | |
65 | waitforTimeout: 5000, | |
66 | // | |
67 | // Default timeout in milliseconds for request | |
68 | // if browser driver or grid doesn't send response | |
69 | connectionRetryTimeout: 120000, | |
70 | // | |
71 | // Default request retries count | |
72 | connectionRetryCount: 3, | |
73 | ||
74 | // Framework you want to run your specs with. | |
75 | // The following are supported: Mocha, Jasmine, and Cucumber | |
76 | // see also: https://webdriver.io/docs/frameworks | |
77 | // | |
78 | // Make sure you have the wdio adapter package for the specific framework installed | |
79 | // before running any tests. | |
80 | framework: 'mocha', | |
81 | // | |
82 | // The number of times to retry the entire specfile when it fails as a whole | |
83 | specFileRetries: 1, | |
84 | // | |
85 | // Delay in seconds between the spec file retry attempts | |
86 | // specFileRetriesDelay: 0, | |
87 | // | |
88 | // Whether or not retried specfiles should be retried immediately or deferred to the end of the queue | |
89 | // specFileRetriesDeferred: false, | |
90 | // | |
91 | // Test reporter for stdout. | |
92 | // The only one supported by default is 'dot' | |
93 | // see also: https://webdriver.io/docs/dot-reporter | |
94 | reporters: [ 'spec' ], | |
95 | ||
96 | // | |
97 | // Options to be passed to Mocha. | |
98 | // See the full list at http://mochajs.org/ | |
99 | mochaOpts: { | |
100 | ui: 'bdd', | |
101 | timeout: 60000, | |
102 | bail: true | |
103 | }, | |
104 | ||
105 | autoCompileOpts: { | |
106 | autoCompile: true, | |
107 | ||
108 | tsNodeOpts: { | |
109 | project: require('path').join(__dirname, './tsconfig.json') | |
110 | }, | |
111 | ||
112 | tsConfigPathsOpts: { | |
113 | baseUrl: './', | |
114 | paths: { | |
115 | '@server/*': [ '../../server/*' ], | |
116 | '@shared/*': [ '../../shared/*' ] | |
117 | } | |
118 | } | |
119 | }, | |
120 | ||
121 | before: function () { | |
122 | require('expect-webdriverio') | |
123 | require('./src/commands/upload') | |
124 | } | |
125 | } as Partial<WebdriverIO.Config> |