summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAllen Hutchison <[email protected]>2025-05-30 15:30:09 -0700
committerGitHub <[email protected]>2025-05-30 15:30:09 -0700
commita60e51f44d84b1a13c335e6b75339b8ad8c544bb (patch)
tree60b9f49de0c701774d5384734a0ee97f930b7148
parent01768d7759b81a0f1483c751206f6afcae6fc505 (diff)
fix(ci): Adjust reporting for PRs from forks (#627)
-rw-r--r--.github/workflows/ci.yml13
1 files changed, 10 insertions, 3 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 835c6ccf..8937f415 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -90,15 +90,22 @@ jobs:
- name: Run tests and generate reports
run: NO_COLOR=true npm run test:ci
- - name: Publish Test Report
+ - name: Publish Test Report (for non-forks)
+ if: always() && (github.event.pull_request.head.repo.full_name == github.repository)
uses: dorny/test-reporter@v1
- if: always()
with:
name: Test Results (Node ${{ matrix.node-version }})
path: packages/*/junit.xml
reporter: java-junit
fail-on-error: 'false'
+ - name: Upload Test Results Artifact (for forks)
+ if: always() && (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository)
+ uses: actions/upload-artifact@v4
+ with:
+ name: test-results-fork-${{ matrix.node-version }}
+ path: packages/*/junit.xml
+
- name: Upload coverage reports
uses: actions/upload-artifact@v4
if: always()
@@ -110,7 +117,7 @@ jobs:
name: Post Coverage Comment
runs-on: ubuntu-latest
needs: test
- if: always() && github.event_name == 'pull_request'
+ if: always() && github.event_name == 'pull_request' && (github.event.pull_request.head.repo.full_name == github.repository)
continue-on-error: true
permissions:
contents: read # For checkout