diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 19aa441b..901d3489 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -50,3 +50,10 @@ jobs: fi - name: Unit tests run: make test-cover + - name: Upload coverage to Codecov + uses: codecov/codecov-action@v4.0.1 + env: + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} + with: + files: coverage.txt + fail_ci_if_error: true diff --git a/.github/workflows/python-tests.yml b/.github/workflows/python-tests.yml index 08ffd056..323575a7 100644 --- a/.github/workflows/python-tests.yml +++ b/.github/workflows/python-tests.yml @@ -59,6 +59,14 @@ jobs: else nox --python=${{ matrix.python }} fi + - name: Upload coverage report + uses: codecov/codecov-action@v4.0.1 + if: always() && matrix.session == 'tests' + env: + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} + with: + files: coverage.xml + fail_ci_if_error: true - name: Upload documentation if: matrix.session == 'docs-build' uses: actions/upload-artifact@v4