-
Notifications
You must be signed in to change notification settings - Fork 3
38 lines (30 loc) · 976 Bytes
/
ctest.yml
File metadata and controls
38 lines (30 loc) · 976 Bytes
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
name: ctest
on: [push, pull_request]
jobs:
build:
strategy:
# dont want to fail early if one of the tests breaks
fail-fast: false
matrix:
# os: [windows-latest, ubuntu-latest, macos-latest]
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: Install gcc-12 (ubuntu)
if: ${{ matrix.os == 'ubuntu-latest' }}
run: |
sudo add-apt-repository ppa:ubuntu-toolchain-r/ppa -y
sudo apt-get update
sudo apt upgrade -y
sudo apt install gcc-12 g++-12 cmake libminizip-dev -y
sudo unlink /usr/bin/gcc
sudo unlink /usr/bin/g++
sudo ln -s /usr/bin/gcc-12 /usr/bin/gcc
sudo ln -s /usr/bin/g++-12 /usr/bin/g++
- name: Configure CMake
run: cmake --preset testing
- name: Build
run: cmake --build --preset testing --parallel 3
- name: Test
run: ctest --test-dir build/testing --parallel 3