Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add HTML test coverage report #177

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .github/workflows/poetry.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,13 +87,23 @@ jobs:
- name: Generate coverage report
run: poetry run coverage lcov -o coverage.lcov
if: startsWith(matrix.os, 'ubuntu')
- name: Generate coverage HTML report
run: poetry run coverage html
if: startsWith(matrix.os, 'ubuntu')
- name: Upload coverage report
uses: coverallsapp/github-action@v2
with:
file: coverage.lcov
parallel: true
flag-name: run ${{ join(matrix.*, ' - ') }}
if: startsWith(matrix.os, 'ubuntu')
- name: Upload coverage HTML report
uses: actions/upload-artifact@v4
with:
name: code-coverage-report
path: htmlcov
if: startsWith(matrix.os, 'ubuntu') && startsWith(matrix.python-version, '3.12')

finish:
needs: tests
runs-on: ubuntu-latest
Expand Down
3 changes: 3 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,9 @@ relative_files = true
[tool.coverage.report]
fail_under = 99

[tool.coverage.html]
show_contexts = true

[tool.pyright]
exclude = [
"**/__pycache__",
Expand Down