forked from patternfly/patternfly-elements
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwdio.conf.js
More file actions
66 lines (62 loc) · 1.59 KB
/
Copy pathwdio.conf.js
File metadata and controls
66 lines (62 loc) · 1.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
const { join } = require("path");
const { exec } = require("child_process");
const argv = require("yargs").argv;
const patterns = argv._.length > 1 ? argv._.slice(1) : [];
require("dotenv").config();
let proc;
exports.config = {
logLevel: "error",
framework: "mocha",
mochaOpts: {
colors: true,
timeout: 90000
},
user: process.env.BROWSERSTACK_USER,
key: process.env.BROWSERSTACK_KEY,
baseUrl: "http://localhost:8080/",
specs: [`./elements/${patterns.length > 0 ? `+(${patterns.join("|")})` : "*"}/test/*_e2e.js`],
reporters: ["spec"],
maxInstances: 3,
capabilities: [
{
os: "OS X",
browserName: "chrome",
browser_version: "83.0",
resolution: "1920x1080",
"browserstack.local": "true",
"browserstack.selenium_version": "3.5.2"
},
{
os: "Windows",
os_version: "10",
browserName: "IE",
browser_version: "11.0",
resolution: "1920x1080",
"browserstack.local": "true",
"browserstack.selenium_version": "3.5.2"
}
],
services: [
["browserstack", { browserstackLocal: true }],
[
"image-comparison",
{
baselineFolder: join(process.cwd(), "./test/vrt-baseline/"),
formatImageName: `{tag}`,
screenshotPath: join(process.cwd(), "./test/vrt-snapshots"),
savePerInstance: true,
autoSaveBaseline: true,
blockOutStatusBar: true,
blockOutToolBar: true,
disableCSSAnimation: true,
hideScrollBars: true
}
]
],
onPrepare: () => {
proc = exec("http-server");
},
onComplete: () => {
proc.kill();
}
};