diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b683c50a..fea4e0fd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,16 +44,24 @@ jobs: env: UV_PYTHON: ${{ matrix.python-version }} - # Consumed by the weekly coverage report, which reads the artifact from - # the newest successful run on main. Name is per-matrix-version because - # upload-artifact@v4 requires unique names within a run. - - name: Upload coverage report - uses: actions/upload-artifact@v4 + # Shared with the other repos' coverage jobs. It lives in its own public + # repo because a public repository -- this one -- cannot resolve an action + # from a private one. An earlier attempt to consume it from the private + # internal-workflows repo failed at `Set up job` on every matrix leg with + # "Unable to resolve action, not found", so no tests ran at all. + # + # Pinned by commit rather than tag: a tag can be repointed at new code, + # and pinning means a change to the action cannot reach us until we bump + # it deliberately. + - name: Coverage summary if: always() + uses: runpod/coverage-summary-action@65b35a32ecfd9c2f0dc2352394eca1decfba4915 with: - name: coverage-${{ matrix.python-version }} - path: coverage.xml - if-no-files-found: error + format: cobertura + coverage-file: coverage.xml + results: pytest-results.xml + artifact-name: coverage-${{ matrix.python-version }} + if-no-files-found: warn e2e: if: github.event_name != 'schedule' && github.repository == 'runpod/runpod-python' diff --git a/.gitignore b/.gitignore index eb63accf..ed28f0f3 100644 --- a/.gitignore +++ b/.gitignore @@ -56,6 +56,7 @@ htmlcov/ .cache nosetests.xml coverage.xml +pytest-results.xml *.cover *.py,cover .hypothesis/ diff --git a/Makefile b/Makefile index 2f72cb1a..88592bac 100644 --- a/Makefile +++ b/Makefile @@ -9,7 +9,7 @@ test: uv run pytest test-coverage: - uv run pytest --cov=runpod --cov-report=term-missing --cov-report=xml + uv run pytest --cov=runpod --cov-branch --cov-report=term-missing --cov-report=xml --junitxml=pytest-results.xml # --- Build --- build: