Installation instructions for Vampyr #202
Workflow file for this run
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: Compute code coverage for VAMPyR | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
env: | |
BUILD_TYPE: Debug | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up environment | |
uses: conda-incubator/setup-miniconda@v2 | |
with: | |
auto-update-conda: true | |
auto-activate-base: false | |
activate-environment: vampyr-gha | |
environment-file: environment.yml | |
channel-priority: true | |
python-version: 3.9 | |
- name: Configure | |
shell: bash -l {0} | |
run: | | |
cmake -S. -Bbuild -DCMAKE_BUILD_TYPE=$BUILD_TYPE -GNinja -DCMAKE_INSTALL_PREFIX=$GITHUB_WORKSPACE/Software/VAMPyR -DCMAKE_VERBOSE_MAKEFILE=ON -DENABLE_CODE_COVERAGE=ON | |
- name: Build | |
shell: bash -l {0} | |
env: | |
CXXFLAGS: "" | |
run: | | |
cmake --build build --config $BUILD_TYPE --target install -- -v -d stats | |
- name: Test VAMPyR and generate coverage report | |
shell: bash -l {0} | |
run: | | |
cd build/lib/python3.9/site-packages | |
python -m pytest --cov=vampyr --cov-report=xml --doctest-modules | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v1 |