Skip to content

Commit

Permalink
Config code coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
banghuazhao committed Sep 22, 2024
1 parent e0125b6 commit e9ddcda
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,12 @@ jobs:
pip install -r requirements.txt
# Run tests
- name: Run tests
- name: Run tests with coverage
run: |
source venv/bin/activate
PYTHONPATH=./ pytest
PYTHONPATH=./ pytest --cov=app .
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
3 changes: 3 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ anyio==3.7.1
certifi==2024.8.30
charset-normalizer==3.3.2
click==8.1.7
codecov==2.1.13
coverage==7.2.7
exceptiongroup==1.2.2
fastapi==0.103.2
h11==0.14.0
Expand All @@ -17,6 +19,7 @@ pluggy==1.2.0
pydantic==2.5.3
pydantic_core==2.14.6
pytest==7.4.4
pytest-cov==4.1.0
requests==2.31.0
sniffio==1.3.1
starlette==0.27.0
Expand Down

0 comments on commit e9ddcda

Please sign in to comment.