mirror of
https://github.com/catchorg/Catch2.git
synced 2026-01-18 17:21:43 +01:00
Add ASan and TSan builds on Mac
This commit is contained in:
43
.github/workflows/mac-sanitizer-builds.yml
vendored
Normal file
43
.github/workflows/mac-sanitizer-builds.yml
vendored
Normal file
@@ -0,0 +1,43 @@
|
||||
name: Mac Sanitizer Builds
|
||||
|
||||
on: [push, pull_request]
|
||||
|
||||
env:
|
||||
CTEST_OUTPUT_ON_FAILURE: 1
|
||||
CTEST_NO_TESTS_ACTION: error
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ${{matrix.image}}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
image: [macos-15, macos-15-intel]
|
||||
build_type: [Debug]
|
||||
std: [17]
|
||||
sanitizer: [thread, address]
|
||||
include:
|
||||
- sanitizer: thread
|
||||
preset: basic-tests
|
||||
filter: -R ThreadSafetyTests
|
||||
- sanitizer: address
|
||||
preset: most-tests
|
||||
filter:
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Configure
|
||||
|
||||
run: |
|
||||
CFXXFLAGS=-fsanitize=${{matrix.sanitizer}},undefined
|
||||
cmake --preset ${{matrix.preset}} -GNinja \
|
||||
-DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
|
||||
-DCMAKE_CXX_STANDARD=${{matrix.std}} \
|
||||
-DCATCH_BUILD_EXTRA_TESTS=ON
|
||||
|
||||
- name: Build
|
||||
run: cmake --build build
|
||||
|
||||
- name: Test
|
||||
run: ctest --test-dir build ${{matrix.filter}}
|
||||
Reference in New Issue
Block a user