-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (40 loc) · 1.16 KB
/
utests.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
name: Unit tests
on:
push:
branches: '*'
pull_request:
branches: [ "master" ]
env:
BUILD_TYPE: Debug
jobs:
build:
strategy:
matrix:
include:
- qt_version: '6.6'
qt_arch: 'gcc_64'
- qt_version: '6.7'
qt_arch: 'linux_gcc_64'
- qt_version: '6.8'
qt_arch: 'linux_gcc_64'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: 'recursive'
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -y nlohmann-json3-dev libutfcpp-dev libgd-dev xvfb libxcb-cursor0
shell: bash
- name: Install Qt
uses: jurplel/install-qt-action@v4
with:
version: '${{ matrix.qt_version }}'
arch: '${{ matrix.qt_arch }}'
- name: Configure CMake
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DSCRATCHCPPRENDER_BUILD_UNIT_TESTS=ON
- name: Build
run: xvfb-run cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -j$(nproc --all)
- name: Run unit tests
run: xvfb-run ctest --test-dir build -V