diff --git a/.github/workflows/zephyr-4.x.yml b/.github/workflows/zephyr-4.x.yml index ab023a8f42..1350947dc9 100644 --- a/.github/workflows/zephyr-4.x.yml +++ b/.github/workflows/zephyr-4.x.yml @@ -48,9 +48,11 @@ jobs: id: src run: | if [[ "${{ github.event_name }}" == "pull_request" ]]; then - # Fetch via upstream PR ref so renames, deletes, or visibility changes on the fork do not break us + # Fetch via upstream PR ref so renames, deletes, or visibility changes on the fork do not break us. + # Use the /merge ref (PR merged into the base branch) instead of /head so we test master+PR, + # picking up fixes already on master rather than testing the PR branch in isolation. echo "repo=https://github.com/${{ github.repository }}" >> "$GITHUB_OUTPUT" - echo "branch=refs/pull/${{ github.event.pull_request.number }}/head" >> "$GITHUB_OUTPUT" + echo "branch=refs/pull/${{ github.event.pull_request.number }}/merge" >> "$GITHUB_OUTPUT" else echo "repo=https://github.com/${{ github.repository }}" >> "$GITHUB_OUTPUT" echo "branch=${{ github.ref_name }}" >> "$GITHUB_OUTPUT"