Skip to content

Commit

Permalink
ci: add codecov
Browse files Browse the repository at this point in the history
  • Loading branch information
JacobCoffee committed Apr 26, 2024
1 parent aa86be0 commit 3f78032
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,3 +125,33 @@ jobs:
path: |
docs/_build/html
.pr_number
upload-test-coverage:
runs-on: ubuntu-latest
needs:
- test
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.12"

- name: Download Artifacts
uses: actions/download-artifact@v3
with:
name: coverage-data

- name: Combine coverage files
run: |
python -Im pip install coverage covdefaults
python -Im coverage combine
python -Im coverage xml -i
- name: Fix coverage file name
run: sed -i "s/home\/runner\/work\/litestar\/advanced-alchemy/github\/workspace/g" coverage.xml

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
with:
files: coverage.xml
token: ${{ secrets.CODECOV_TOKEN }}

0 comments on commit 3f78032

Please sign in to comment.