Skip to content

armgit / nutch

Public Imported from GitHub
0

Apache Nutch is an extensible and scalable web crawler

NUTCH-3143 GitHub workflow does not run all unit tests (#884)

Lewis John McGibbneyec8747a3feb4
diff --git a/.github/workflows/junit-report.yml b/.github/workflows/junit-report.yml
index e7658ffea..80958285c 100644
--- a/.github/workflows/junit-report.yml
+++ b/.github/workflows/junit-report.yml
@@ -25,33 +25,49 @@ jobs:
checks:
runs-on: ubuntu-latest
steps:
- - name: Download Test Report
+ - name: Download Test Report (Ubuntu)
uses: dawidd6/action-download-artifact@v11
with:
- name: junit-test-results
+ name: junit-test-results-ubuntu-latest
workflow: master-build.yml
run_id: ${{ github.event.workflow_run.id }}
+ path: ./results-ubuntu
+ continue-on-error: true
+ - name: Download Test Report (macOS)
+ uses: dawidd6/action-download-artifact@v11
+ with:
+ name: junit-test-results-macos-latest
+ workflow: master-build.yml
+ run_id: ${{ github.event.workflow_run.id }}
+ path: ./results-macos
+ continue-on-error: true
- name: Publish Test Report
uses: mikepenz/action-junit-report@v5
with:
report_paths: |-
- ./test/TEST-*.xml
- ./**/test/TEST-*.xml
+ ./results-ubuntu/**/TEST-*.xml
+ ./results-macos/**/TEST-*.xml
check_name: |-
JUnit Test Report
JUnit Test Report Plugins
commit: ${{ github.event.workflow_run.head_sha }}
fail_on_failure: false
- fail_on_parse_error: false # temporary while debugging missing result for TestMimeUtil
+ fail_on_parse_error: false
require_tests: true
require_passed_tests: true
include_passed: false
- include_skipped: true
check_annotations: true
+ annotate_notice: true
job_summary: true
+ detailed_summary: true
+ flaky_summary: true
skip_success_summary: true
include_time_in_summary: true
+ group_suite: true
comment: true
+ updateComment: true
+ skip_comment_without_tests: true
job_name: tests
truncate_stack_traces: false
- pr_id: ${{ github.event.workflow_run.pull_requests[0].number }}
+ annotations_limit: 50
+ pr_id: ${{ github.event.workflow_run.pull_requests[0].number || '' }}
diff --git a/.github/workflows/master-build.yml b/.github/workflows/master-build.yml
index aa9219d28..495c4e318 100644
--- a/.github/workflows/master-build.yml
+++ b/.github/workflows/master-build.yml
@@ -65,7 +65,7 @@ jobs:
java: ['17']
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
- timeout-minutes: 30
+ timeout-minutes: 45
steps:
- uses: actions/checkout@v5
- name: Set up JDK ${{ matrix.java }}
@@ -99,13 +99,16 @@ jobs:
- name: test plugins
if: ${{ steps.filter.outputs.plugins == 'true' && steps.filter.outputs.core == 'false' && steps.filter.outputs.buildconf == 'false' }}
run: ant clean test-plugins -buildfile build.xml
+ # fallback: run all tests if no specific filter matched (e.g., docs-only changes)
+ - name: test all (fallback)
+ if: ${{ steps.filter.outputs.buildconf == 'false' && steps.filter.outputs.core == 'false' && steps.filter.outputs.plugins == 'false' }}
+ run: ant clean test -buildfile build.xml
- name: Upload Test Report
uses: actions/upload-artifact@v4
if: always()
with:
- name: junit-test-results
+ name: junit-test-results-${{ matrix.os }}
path: |
./build/test/TEST-*.xml
./build/**/test/TEST-*.xml
- retention-days: 1
- overwrite: true
\ No newline at end of file
+ retention-days: 1
\ No newline at end of file