Skip to content

Commit 189ebbe

Browse files
committed
Fix CI
1 parent e2ebb3e commit 189ebbe

File tree

4 files changed

+49
-32
lines changed

4 files changed

+49
-32
lines changed

.github/workflows/CI.yml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,15 @@ jobs:
2020

2121
steps:
2222
- uses: actions/checkout@v2
23-
- uses: nanasess/setup-chromedriver@master
24-
with:
25-
chromedriver-version: '79.0.3945.36'
26-
- run: |
27-
export DISPLAY=:99
28-
sudo Xvfb -ac :99 -screen 0 1280x1024x24 > /dev/null 2>&1 & # optional
29-
cp .github/workflows/nightwatch.json .
3023
- name: Use Node.js ${{ matrix.node-version }}
3124
uses: actions/setup-node@v1
3225
with:
3326
node-version: ${{ matrix.node-version }}
27+
- run: |
28+
export DISPLAY=:99
29+
sudo Xvfb -ac :99 -screen 0 1280x1024x24 > /dev/null 2>&1 & # optional
3430
- run: npm ci
3531
- run: npm run build --if-present
36-
- run: npm test
32+
- run: npx nightwatch tests --verbose
3733
env:
3834
CI: true

.github/workflows/nightwatch.json

Lines changed: 0 additions & 23 deletions
This file was deleted.

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,3 @@ wbo-backup.zip
2626

2727
# Nightwatch test results
2828
tests_output/
29-
nightwatch.conf.js

nightwatch.conf.js

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
// Autogenerated by Nightwatch
2+
// Refer to the online docs for more details: https://nightwatchjs.org/gettingstarted/configuration/
3+
const Services = {}; loadServices();
4+
5+
module.exports = {
6+
"src_folders": ["tests"],
7+
8+
"webdriver": {
9+
"start_process": true,
10+
"server_path": "./node_modules/.bin/geckodriver",
11+
"cli_args": [
12+
"--log", "debug"
13+
],
14+
"port": 4444
15+
},
16+
17+
"test_settings": {
18+
"default": {
19+
"desiredCapabilities": {
20+
"browserName": "firefox",
21+
"acceptInsecureCerts": true,
22+
"alwaysMatch": {
23+
"moz:firefoxOptions": {
24+
"args": ["-headless"]
25+
}
26+
}
27+
28+
}
29+
}
30+
}
31+
};
32+
33+
function loadServices() {
34+
try {
35+
Services.seleniumServer = require('selenium-server');
36+
} catch (err) { }
37+
38+
try {
39+
Services.chromedriver = require('chromedriver');
40+
} catch (err) { }
41+
42+
try {
43+
Services.geckodriver = require('geckodriver');
44+
} catch (err) { }
45+
}

0 commit comments

Comments
 (0)