Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update codecov.yml #2400

Merged
merged 1 commit into from
Feb 2, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 13 additions & 4 deletions .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,18 @@ jobs:

- name: Rebase PR Branch on Top of Develop
run: |
git fetch origin
git checkout ${{ github.event.pull_request.head.ref }} # Checkout PR branch
git rebase origin/develop # Rebase PR branch on develop
git fetch origin develop # Fetch latest develop
if [[ "${{ github.event.pull_request.head.repo.full_name }}" == "${{ github.repository }}" ]]; then
# PR is from the same repo
git fetch origin ${{ github.event.pull_request.head.ref }}
git checkout ${{ github.event.pull_request.head.ref }}
else
# PR is from a forked repo
git remote add pr_repo ${{ github.event.pull_request.head.repo.clone_url }}
git fetch pr_repo ${{ github.event.pull_request.head.ref }}
git checkout -b test-rebase FETCH_HEAD
fi
git rebase origin/develop
git push origin +HEAD:test-rebase --force # Push rebased branch

- name: Clone Rebased Branch on King Server
Expand All @@ -38,7 +47,7 @@ jobs:
path: test_results.txt

- name: Upload Coverage to Codecov
if: always() # Ensure it runs even if tests fail
if: always()
uses: codecov/codecov-action@v3
with:
files: ${{ github.workspace }}/CodeCovTestResults.xml
Expand Down
Loading