more assertions #9
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Ubuntu | |
| on: | |
| push: | |
| branches: | |
| - '**' | |
| pull_request: | |
| branches: | |
| - '**' | |
| permissions: | |
| contents: read | |
| checks: write | |
| pull-requests: write | |
| jobs: | |
| build-test: | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - os: ubuntu-22.04 | |
| compiler: gcc | |
| c_compiler: gcc | |
| cxx_compiler: g++ | |
| name: Ubuntu-22.04-GCC | |
| packages: gcc g++ | |
| - os: ubuntu-22.04 | |
| compiler: clang | |
| c_compiler: clang | |
| cxx_compiler: clang++ | |
| name: Ubuntu-22.04-Clang | |
| packages: clang | |
| - os: ubuntu-24.04 | |
| compiler: gcc | |
| c_compiler: gcc | |
| cxx_compiler: g++ | |
| name: Ubuntu-24.04-GCC-Sanitizers | |
| packages: gcc g++ | |
| extra_cmake: '-DHUBERT_ENABLE_SANITIZERS=ON' | |
| - os: ubuntu-24.04 | |
| compiler: clang | |
| c_compiler: clang | |
| cxx_compiler: clang++ | |
| name: Ubuntu-24.04-Clang-Sanitizers | |
| packages: clang | |
| extra_cmake: '-DHUBERT_ENABLE_SANITIZERS=ON' | |
| name: ${{ matrix.name }} | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| with: | |
| lfs: true | |
| - name: Install dependencies | |
| run: | | |
| sudo apt update | |
| sudo apt install -y ninja-build cmake ${{ matrix.packages }} | |
| - name: Configure and build | |
| run: | | |
| cmake . -B build -G Ninja \ | |
| -DCMAKE_BUILD_TYPE=RelWithDebInfo \ | |
| -DCMAKE_C_COMPILER=${{ matrix.c_compiler }} \ | |
| -DCMAKE_CXX_COMPILER=${{ matrix.cxx_compiler }} \ | |
| ${{ matrix.extra_cmake }} | |
| cmake --build build --parallel | |
| - name: Run unit tests | |
| run: | | |
| mkdir -p build/test-results | |
| ./build/hubert.tests --reporter console --reporter junit::out=build/test-results/hubert-tests-${{ matrix.name }}.xml | |
| - name: Upload JUnit XML artifact | |
| if: ${{ always() }} | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: junit-${{ matrix.name }} | |
| path: build/test-results/*.xml | |
| - name: Test Report | |
| uses: dorny/test-reporter@v3 | |
| if: ${{ always() }} | |
| with: | |
| name: Unit Tests (${{ matrix.os }}) | |
| path: build/test-results/hubert-tests-${{ matrix.name }}.xml | |
| reporter: java-junit | |
| fail-on-error: "false" |