Skip to content

Commit af9b9e7

Browse files
committed
Add sanitize job
1 parent 47b448e commit af9b9e7

File tree

1 file changed

+22
-1
lines changed

1 file changed

+22
-1
lines changed

.github/workflows/ci.yml

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
strategy:
1212
fail-fast: false
1313
matrix:
14-
os: [ubuntu-latest, macos-latest, windows-latest]
14+
os: [ ubuntu-latest, macos-latest, windows-latest ]
1515

1616
runs-on: ${{ matrix.os }}
1717

@@ -41,3 +41,24 @@ jobs:
4141
# Run Tests
4242
- name: Run tests
4343
run: ctest --test-dir build --output-on-failure -C Debug
44+
45+
sanitize:
46+
runs-on: ubuntu-latest
47+
steps:
48+
- uses: actions/checkout@v4
49+
50+
- name: Configure (ASan + UBSan)
51+
run: >
52+
cmake -S . -B build-sanitize
53+
-DCMAKE_C_COMPILER=clang
54+
-DSMILE_DEV=ON
55+
-DSMILE_INFO=OFF
56+
-DSMILE_WARN=OFF
57+
-DCMAKE_C_FLAGS="-fsanitize=address,undefined -fno-omit-frame-pointer"
58+
-DCMAKE_EXE_LINKER_FLAGS="-fsanitize=address,undefined"
59+
60+
- name: Build
61+
run: cmake --build build-sanitize --config Debug
62+
63+
- name: Run tests
64+
run: ctest --test-dir build-sanitize --output-on-failure -C Debug

0 commit comments

Comments
 (0)