Skip to content

Commit

Permalink
Codecov and license badges
Browse files Browse the repository at this point in the history
  • Loading branch information
robin-janssen committed Oct 17, 2024
1 parent 5cd2f0b commit 96af6ad
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 5 deletions.
18 changes: 13 additions & 5 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -94,13 +94,21 @@ jobs:
- name: Run pytest and generate coverage report
if: env.is-merge == 'false' # Skip if it's a merge commit
run: |
poetry run pytest --cov-report=term-missing:skip-covered --cov=codes test/ | tee pytest-coverage.txt
poetry run pytest --cov-report=term-missing:skip-covered --cov=codes test/ --cov-report=xml:coverage.xml
- name: Pytest coverage comment
if: env.is-merge == 'false' # Skip if it's a merge commit
uses: MishaKav/pytest-coverage-comment@main
# - name: Pytest coverage comment
# if: env.is-merge == 'false' # Skip if it's a merge commit
# uses: MishaKav/pytest-coverage-comment@main
# with:
# pytest-coverage-path: ./pytest-coverage.txt

- name: Upload results to Codecov
uses: codecov/codecov-action@v4
with:
pytest-coverage-path: ./pytest-coverage.txt
token: ${{ secrets.CODECOV_TOKEN }} # Only needed for private repos
files: ./coverage.xml # Path to the coverage XML file, adjust if necessary
fail_ci_if_error: true # Optional, ensures the CI fails if Codecov upload fails


docs:
if: github.ref == 'refs/heads/main' || github.event.pull_request.base.ref == 'main' # Only run on the main branch or PRs targeting main
Expand Down
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# CODES Benchmark

[![codecov](https://codecov.io/github/robin-janssen/CODES-Benchmark/graph/badge.svg?token=TNF9ISCAJK)](https://codecov.io/github/robin-janssen/CODES-Benchmark)

![Static Badge](https://img.shields.io/badge/license-GPLv3-blue)


## Benchmarking Coupled ODE Surrogates

This repo aims to provide a way of benchmarking surrogate models for coupled ODE systems, as can be found in the context of chemical reaction networks.
Expand Down

0 comments on commit 96af6ad

Please sign in to comment.