-
Notifications
You must be signed in to change notification settings - Fork 71
77 lines (68 loc) · 1.8 KB
/
cmake.yml
File metadata and controls
77 lines (68 loc) · 1.8 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
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
name: cmake
on:
push:
branches: [main]
paths:
- ".github/workflows/cmake.yml"
- "include/**"
- "src/**"
- "tests/**"
- "CMakeLists.txt"
pull_request:
branches: [main]
paths:
- ".github/workflows/cmake.yml"
- "include/**"
- "src/**"
- "tests/**"
- "config/**"
- "CMakeLists.txt"
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- os: windows-2025
build_type: RelWithDebInfo
cc: clang
cxx: clang++
- os: ubuntu-24.04
build_type: Debug
cc: clang
cxx: clang++
- os: macos-15
build_type: Debug
cc: clang
cxx: clang++
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Pixi
uses: prefix-dev/setup-pixi@v0.8.1
with:
pixi-version: v0.39.0
environments: develop
activate-environment: true
cache: true
locked: true
- name: Build clice
shell: bash
run: |
cmake -B build -G Ninja \
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
-DCMAKE_C_COMPILER=${{ matrix.cc }} \
-DCMAKE_CXX_COMPILER=${{ matrix.cxx }} \
-DCLICE_ENABLE_TEST=ON \
-DCLICE_CI_ENVIRONMENT=ON
cmake --build build
- name: Run tests
shell: bash
run: |
EXE_EXT=""
if [[ "${{ runner.os }}" == "Windows" ]]; then
EXE_EXT=".exe"
fi
./build/bin/unit_tests${EXE_EXT} --test-dir="./tests/data"
uv run --project tests pytest -s --log-cli-level=INFO tests/integration --executable=./build/bin/clice${EXE_EXT}