Skip to content

Commit

Permalink
Try to fix CodeCov report uploads in pytest workflow. (#3827)
Browse files Browse the repository at this point in the history
* Try to fix CodeCov report uploads in pytest workflow.

* Test additional codecov action options on unit tests.

* Disable all codecov plugins.

* Re-enable docs and integration tests.
  • Loading branch information
zaneselvans authored Sep 4, 2024
1 parent db43bb2 commit 963913b
Showing 1 changed file with 13 additions and 7 deletions.
20 changes: 13 additions & 7 deletions .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -223,11 +223,6 @@ jobs:
- name: List downloaded files
run: |
find coverage -type f
- name: Upload test coverage report to CodeCov
uses: codecov/codecov-action@v4
with:
directory: coverage
token: ${{ secrets.CODECOV_TOKEN }}
- name: Install Micromamba
uses: mamba-org/setup-micromamba@v1
with:
Expand All @@ -236,9 +231,20 @@ jobs:
create-args: >-
python=3.12
coverage>=7.6.1
- name: Combine coverage data and check that we have required coverage
# Required coverage is set in pyproject.toml section [tool.coverage.report]
- name: Combine coverage data and output XML report
run: |
micromamba run -n coverage coverage combine coverage/*/.coverage
micromamba run -n coverage coverage xml --fail-under=0
- name: Upload XML coverage report to CodeCov
uses: codecov/codecov-action@v4
with:
disable_search: true
file: ./coverage.xml
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true # optional (default = false)
plugin: noop
verbose: true
- name: Display coverage report and ensure it meets required minimum
# Required coverage is set in pyproject.toml section [tool.coverage.report]
run: |
micromamba run -n coverage coverage report

0 comments on commit 963913b

Please sign in to comment.