From aab112b1f1080421b9648cdfad3452ee8289640b Mon Sep 17 00:00:00 2001 From: Mikael Simberg Date: Fri, 26 Jul 2024 14:01:09 +0200 Subject: [PATCH] Run tests with address, undefined, and thread sanitizer in CI --- .github/workflows/build_and_test.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index 75ee195..1725307 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -11,6 +11,7 @@ jobs: strategy: matrix: buildtype: [debug, release] + sanitizer: [none, address, undefined, thread] runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 @@ -19,13 +20,14 @@ jobs: - name: Set up ccache uses: hendrikmuhs/ccache-action@v1.2 with: - key: ccache-linux-${{ matrix.buildtype }} + key: ccache-linux-${{ matrix.buildtype }}-${{ matrix.sanitizer }} - name: Setup compiler and build tools run: sudo apt install --no-install-recommends --yes g++-12 meson ninja-build - name: Configure run: | CXX="ccache g++-12" meson setup \ --buildtype ${{ matrix.buildtype }} \ + -Db_sanitize=${{ matrix.sanitizer }} \ --warnlevel 3 \ --werror \ build .