mirror of
https://github.com/tiennm99/litellm.git
synced 2026-08-02 12:21:10 +00:00
Revert to --cov=litellm, add checkout and root_dir to upload job
This commit is contained in:
@@ -172,8 +172,8 @@ jobs:
|
||||
--reruns-delay 1 \
|
||||
--dist=loadscope \
|
||||
--durations=20 \
|
||||
--cov=. \
|
||||
--cov-report=xml \
|
||||
--cov=litellm \
|
||||
--cov-report=xml:coverage.xml \
|
||||
--cov-config=pyproject.toml
|
||||
|
||||
- name: Save coverage report
|
||||
@@ -181,7 +181,7 @@ jobs:
|
||||
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
|
||||
with:
|
||||
name: coverage-${{ matrix.test-group.name }}
|
||||
path: coverage-${{ matrix.test-group.name }}.xml
|
||||
path: coverage.xml
|
||||
retention-days: 1
|
||||
|
||||
upload-coverage:
|
||||
@@ -195,22 +195,27 @@ jobs:
|
||||
pull-requests: write # Required for Codecov PR comments
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0
|
||||
|
||||
- name: Download all coverage reports
|
||||
uses: actions/download-artifact@95815c38cf2ff2164869cbab79da8d1f422bc89e # v4.2.1
|
||||
with:
|
||||
pattern: coverage-*
|
||||
path: coverage-reports
|
||||
merge-multiple: true
|
||||
|
||||
- name: Debug coverage paths
|
||||
run: |
|
||||
echo "=== source tags ==="
|
||||
grep -h "<source>" coverage-root.xml | head -5
|
||||
grep -h "<source>" coverage-reports/coverage.xml | head -5
|
||||
echo "=== filename samples ==="
|
||||
grep -h "filename=" coverage-root.xml | head -10
|
||||
grep -h "filename=" coverage-reports/coverage.xml | head -10
|
||||
|
||||
- name: Upload to Codecov
|
||||
uses: codecov/codecov-action@aa56896cf108bd10b5eb883cd1d24196da57f695 # v5.5.4
|
||||
with:
|
||||
use_oidc: true
|
||||
files: "*.xml"
|
||||
directory: coverage-reports
|
||||
root_dir: ${{ github.workspace }}
|
||||
fail_ci_if_error: false
|
||||
|
||||
+1
-7
@@ -211,11 +211,5 @@ filterwarnings = [
|
||||
]
|
||||
|
||||
[tool.coverage.run]
|
||||
source = ["."]
|
||||
omit = [
|
||||
"tests/*",
|
||||
"enterprise/*",
|
||||
".venv/*",
|
||||
"*/site-packages/*",
|
||||
]
|
||||
source = ["litellm"]
|
||||
relative_files = true
|
||||
|
||||
Reference in New Issue
Block a user