From 97b9a5aea5b8eca9b76e0f6e6c6ceadaaa531706 Mon Sep 17 00:00:00 2001 From: zacharyburnett Date: Tue, 25 Jun 2024 14:33:29 -0400 Subject: [PATCH] add pull request coverage diff report --- .github/workflows/ci.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f446dca1..2f483690 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,3 +40,19 @@ jobs: envs: | - linux: py311-jwst-xdist - linux: py311-romancal-xdist + report_diff_coverage: + needs: [ test ] + if: github.event_name == 'pull_request' + runs-on: ubuntu-latest + steps: + - uses: actions/setup-python@v5 + - run: pip install diff-cover coverage + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + - run: pip install . + - uses: actions/download-artifact@v4 + with: + name: .coverage + - run: coverage xml + - run: diff-cover coverage.xml --compare-branch origin/${{ github.base_ref }} --markdown-report $GITHUB_STEP_SUMMARY