diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index 896d0fc..ec8b712 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -39,11 +39,11 @@ jobs: - name: Generate coverage.json run: | - python -m coverage json --include=$(git diff --name-status main codebasin/*.py | grep "^M" | awk '{ print $2 }' | paste -sd,) + python -m coverage json --include=$(git diff --name-status ${{ github.event.pull_request.base.sha }} codebasin/*.py | grep "^M" | awk '{ print $2 }' | paste -sd,) - name: Check coverage against latest commits run: | FROM=${{ github.event.pull_request.base.sha }} - TO=${{ github.event.pull_request.head.sha }} + TO=${{ github.sha }} COMMITS=$(git rev-list $FROM..$TO) python .github/workflows/check-coverage.py coverage.json --commits $COMMITS