Skip to content

Commit

Permalink
Enable code coverage measurement for tests (#948)
Browse files Browse the repository at this point in the history
  • Loading branch information
abhahn committed Jun 27, 2024
1 parent a0fbf15 commit ff30796
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 3 deletions.
Empty file.
19 changes: 17 additions & 2 deletions .github/workflows/python-app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,22 @@ jobs:
- name: Test with pytest
run: |
export PYTHONPATH=$(pwd)
pytest -v --show-capture=stdout -k "not integration"
coverage run --omit=tests/integration_tests -m pytest -v --show-capture=stdout -k "not integration"
coverage report -m
coverage xml
- name: Code Coverage Report
uses: irongut/[email protected]
with:
filename: coverage.xml
badge: true
fail_below_min: true
format: markdown
hide_branch_rate: false
hide_complexity: true
indicators: true
output: both
thresholds: '60 80'

test_windows:
runs-on:
Expand All @@ -47,4 +62,4 @@ jobs:
- name: Test with pytest
run: |
$env:PYTHONPATH=$pwd
pytest -v --show-capture=stdout -k "not integration"
pytest -v --show-capture=stdout -k "not integration"
3 changes: 2 additions & 1 deletion requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,5 @@ pytest==7.4.0
pytest-asyncio==0.23.2
azure-storage-blob
chardet
azure-keyvault-secrets
azure-keyvault-secrets
coverage

0 comments on commit ff30796

Please sign in to comment.