-
Notifications
You must be signed in to change notification settings - Fork 16
59 lines (55 loc) · 1.64 KB
/
test.yml
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
# Run Extension tests
name: test
# Controls when the workflow will run
on:
# Triggers the workflow on push events for the "main" branch
push:
branches: [ main ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
test-smoke:
name: ${{ matrix.version }}-${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
version: [R2021a, latest]
os: [windows-latest, ubuntu-latest, macos-13]
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: Set up MATLAB
uses: matlab-actions/setup-matlab@v2
with:
release: ${{ matrix.version }}
- name: Setup node
uses: actions/setup-node@v4
with:
"node-version": 18.x
- name: npm clean install
run: npm ci
- name: Start Xvfb
run: /usr/bin/Xvfb :17 -screen 0 1024x768x24 > /dev/null 2>&1 & echo "Started xvfb"
shell: bash
if: ${{ success() && matrix.os == 'ubuntu-latest' }}
- name: Package vsix
run: npm run package
- name: npm install
run: npm install
- name: Run UI tests
run: npm run test-ui
env:
MLM_WEB_LICENSE: true
MLM_WEB_ID: ${{secrets.MLM_WEB_ID}}
MLM_WEB_USER_CRED: ${{secrets.MLM_WEB_USER_CRED}}
DISPLAY: ":17.0"
- name: Run Smoke tests
run: npm run test-smoke
env:
MLM_WEB_LICENSE: true
MLM_WEB_ID: ${{secrets.MLM_WEB_ID}}
MLM_WEB_USER_CRED: ${{secrets.MLM_WEB_USER_CRED}}
DISPLAY: ":17.0"