From 8a7dbec79b7427d87a7b4f1b8979d8c59c36ac90 Mon Sep 17 00:00:00 2001 From: "Patrick J. Roddy" Date: Fri, 4 Oct 2024 10:21:27 +0100 Subject: [PATCH] gh-319: run coverage in parallel and aggregate results (#320) Closes #319. Reading the documentation of the action this is what you are _meant_ to do when you are using matrix builds. I've used this before. https://github.com/coverallsapp/github-action?tab=readme-ov-file#complete-parallel-job-example This has also fixed the `Tree` section of the `coveralls` UI which was previously just showing `core`/`ext` (and the files therein). ![image](https://github.com/user-attachments/assets/925851e6-e429-497a-b694-2fe1a188590f) --- .github/workflows/test.yml | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 02b622d0..2ed6b36a 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -52,9 +52,22 @@ jobs: run: nox -s coverage-${{ matrix.python-version }} --verbose - name: Coveralls requires XML report run: coverage xml - - uses: coverallsapp/github-action@v2 + - name: Run Coveralls in parallel + uses: coverallsapp/github-action@v2 with: - github-token: ${{ secrets.GITHUB_TOKEN }} + flag-name: run-${{ matrix.python-version }} + parallel: true + + aggregate-tests: + needs: tests + if: ${{ always() }} + runs-on: ubuntu-latest + steps: + - name: Coveralls finished + uses: coverallsapp/github-action@v2 + with: + parallel-finished: true + carryforward: run-3.8,run-3.9,run-3.10,run-3.11,run-3.12 build: name: Build