Replaces expect in windows test action #82
This file contains 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: Generate Test Coverage | |
on: | |
push: | |
branches: [ "master" ] | |
pull_request: | |
branches: [ "master" ] | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
# Set fail-fast to false to ensure that feedback is delivered for all | |
# matrix combinations. Consider changing this to true when your workflow | |
# is stable. | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest] | |
build_type: [Debug] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup Miniconda | |
uses: conda-incubator/[email protected] | |
with: | |
auto-activate-base: false | |
environment-file: environment-coverage.yml | |
activate-environment: ll-cpp-coverage | |
miniforge-version: latest | |
use-mamba: true | |
channels: conda-forge | |
- name: Configure CMake | |
shell: bash -el {0} | |
run: > | |
cmake -B build | |
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} | |
-DBUILD_TESTS=ON | |
-DENABLE_TEST_COVERAGE=ON | |
- name: Build | |
shell: bash -el {0} | |
run: cmake --build build --config ${{ matrix.build_type }} | |
- name: Generate Test Coverage | |
working-directory: build | |
shell: bash -el {0} | |
run: make coverage | |
- name: Coveralls GitHub Action | |
uses: coverallsapp/[email protected] | |
with: | |
file: build/coverage.json |