Skip to content

Commit

Permalink
ci: fix coverage report generation🔧
Browse files Browse the repository at this point in the history
  • Loading branch information
KarelZe committed Dec 2, 2024
1 parent bd295f3 commit 8b498b0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/action_python.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ jobs:
run: uv sync --all-extras --dev
- name: Test with pytest
run: |
uv run pytest --cov=src tests/ --doctest-modules --junitxml=cover/xunit-result.xml --cov-report xml:cover/coverage.xml
uv run coverage json -o cover/coverage.json
uv run pytest --cov=src tests/ --junitxml=cover/xunit-result.xml --cov-report xml:cover/coverage.xml
uv run coverage json cover/xunit-result.xml coverage.json
- name: "Extract numbers from cov report"
run: |
export TOTAL=$(python -c "import json;print(json.load(open('cover/coverage.json'))['totals']['percent_covered_display'])")
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ dev-dependencies = [
"mypy>=1.7.1",
"pre-commit>=3.5.0",
"pytest>=7.4.3",
"pytest-cov>=4.1.0",
"pytest-cov",
"ruff>=0.8.1",
"tox>=4.23",
"tox-uv",
Expand Down
2 changes: 1 addition & 1 deletion uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 8b498b0

Please sign in to comment.