-
Notifications
You must be signed in to change notification settings - Fork 32
86 lines (70 loc) · 1.88 KB
/
run_tests_octave.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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
---
name: 'octave: tests'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
on:
push:
branches:
- main
paths:
- '**.m'
pull_request:
branches: ['*']
env:
OCTFLAGS: --no-gui --no-window-system --silent
jobs:
test:
strategy:
fail-fast: false
matrix:
test: [slow, fast]
runs-on: ubuntu-22.04
steps:
- name: Clone bids-matlab
uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 1
- name: Install dependencies
run: |
sudo apt-get -y -qq update
sudo apt-get -y install unzip wget
- name: Install bids validator
run: npm install -g bids-validator
- name: Install bids-example
run: |
cd tests
make data
- name: Install Moxunit and MOcov
run: |
git clone https://github.com/MOxUnit/MOxUnit.git --depth 1
git clone https://github.com/MOcov/MOcov.git --depth 1
- name: Install octave
run: |
sudo apt-get -y -qq update
sudo apt-get -y install \
octave \
liboctave-dev\
octave-common \
octave-io \
octave-image \
octave-signal \
octave-statistics
make -C MOxUnit install
make -C MOcov install
- name: Install JSONio
run: |
git clone https://github.com/gllmflndn/JSONio.git --depth 1
cd JSONio
mkoctfile --mex jsonread.c jsmn.c -DJSMN_PARENT_LINKS
octave $OCTFLAGS --eval "addpath(fullfile(pwd)); savepath();"
- name: Run fast tests Octave
if: matrix.test == 'fast'
run: |
octave $OCTFLAGS --eval "success = run_tests(); assert(success);"
- name: Run slow tests Octave
if: matrix.test == 'slow'
run: |
export SLOW=true
octave $OCTFLAGS --eval "success = run_tests(); assert(success);"