Skip to content

Commit

Permalink
Merge pull request #647 from bioimage-io/coverage_badge
Browse files Browse the repository at this point in the history
Add coverage badge
  • Loading branch information
FynnBe authored Oct 29, 2024
2 parents a20e58b + e2952b5 commit 9d33e59
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 5 deletions.
17 changes: 16 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,28 @@ jobs:
with:
coverageFile: coverage.xml
token: ${{ secrets.GITHUB_TOKEN }}

- if: matrix.python-version == '3.12'
run: |
pip install genbadge[coverage]
genbadge coverage --input-file coverage.xml --output-file ./dist/coverage/coverage-badge.svg
coverage html -d dist/coverage
- if: matrix.python-version == '3.12'
uses: actions/upload-artifact@v4
with:
name: coverage
retention-days: 1
path: dist


deploy:
needs: [test]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v4
with:
name: coverage
path: dist
- uses: actions/setup-python@v5
with:
python-version: "3.12"
Expand Down
11 changes: 7 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,14 +1,17 @@
__pycache__/
.coverage
.env
.ipynb_checkpoints
.vscode/launch.json
*.DS_Store
*.egg-info/
build/
coverage.xml
dist/
docs/
user_docs/
output/
tests/cache
tests/generated_json_schemas
tmp/
output/
*.DS_Store
.ipynb_checkpoints
user_docs/

1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
[![downloads](https://static.pepy.tech/badge/bioimageio.spec)](https://pepy.tech/project/bioimageio.spec)
[![conda-forge downloads](https://img.shields.io/conda/dn/conda-forge/bioimageio.spec.svg?label=conda-forge)](https://anaconda.org/conda-forge/bioimageio.spec/)
![code style](https://img.shields.io/badge/code%20style-black-000000.svg)
[![coverage](https://bioimage-io.github.io/spec-bioimage-io/coverage/coverage-badge.svg)](https://bioimage-io.github.io/spec-bioimage-io/coverage/index.html)

# Specifications for bioimage.io

Expand Down

0 comments on commit 9d33e59

Please sign in to comment.