-
Notifications
You must be signed in to change notification settings - Fork 9
52 lines (48 loc) · 1.49 KB
/
CI.yml
File metadata and controls
52 lines (48 loc) · 1.49 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
name: CI
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
test:
runs-on: ${{ matrix.os }} # runs a test on Ubuntu, and macOS
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
node: [16]
fail-fast: false
steps:
- uses: actions/checkout@v2
- name: Setup node
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}
- name: NPM Install and Build
run: |
npm install
npm run vscode:prepublish
- name: Install xvfb
run: |
sudo apt-get install -y xvfb libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-xinerama0 libxcb-xinput0 libxcb-xfixes0
if: ${{ runner.os == 'Linux'}}
- name: Run Unit tests
run: xvfb-run --auto-servernum -s '-screen 0 1280x1024x24' npm test --silent
if: ${{ runner.os == 'Linux'}}
- name: Run Unit tests
run: npm test --silent
if: ${{ runner.os != 'Linux'}}
- name: Run UI tests
run: xvfb-run --auto-servernum -s '-screen 0 3840x1080x24' npm run ui-test
if: ${{ runner.os == 'Linux'}}
- name: Run UI tests
run: npm run ui-test
if: ${{ runner.os != 'Linux'}}
- name: Archiving test artifacts
uses: actions/upload-artifact@v2
with:
name: test-artifacts-${{ runner.os }}
path: |
test-resources/screenshots/*.png
test-resources/*.log
if: always()