From cb3ad46597c5fe242c1e5b495a7fb02ad2168be1 Mon Sep 17 00:00:00 2001 From: Rahul Pandey <103115900+rp9-next@users.noreply.github.com> Date: Thu, 29 Aug 2024 11:01:08 +0530 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Elango Cheran --- .github/workflows/icu_exhaustive_tests.yml | 10 +++++----- docs/userguide/dev/ci.md | 13 +++++++++++++ 2 files changed, 18 insertions(+), 5 deletions(-) diff --git a/.github/workflows/icu_exhaustive_tests.yml b/.github/workflows/icu_exhaustive_tests.yml index 8bf9f592c6b6..b8ba813a27e3 100644 --- a/.github/workflows/icu_exhaustive_tests.yml +++ b/.github/workflows/icu_exhaustive_tests.yml @@ -34,7 +34,7 @@ jobs: - uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 - name: Fetch PR Details id: pr-details - if: contains(github.event.comment.body, 'run exhaustive tests') + if: contains(github.event.comment.body, ${{ env.PR_COMMENT_TRIGGER_TEXT }}) run: | echo ${{ secrets.GITHUB_TOKEN }} | gh auth login --with-token gh api "${{ github.event.issue.pull_request.url }}" > pr.json @@ -44,7 +44,7 @@ jobs: echo "SHA=$SHA" >> $GITHUB_ENV - name: Add a check to the PR id: add-check - if: contains(github.event.comment.body, 'run exhaustive tests') + if: contains(github.event.comment.body, ${{ env.PR_COMMENT_TRIGGER_TEXT }}) run: | WORKFLOW_URL="${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" echo $WORKFLOW_URL @@ -72,7 +72,7 @@ jobs: cd icu4j && cat `find . -name surefire-reports -type d -exec grep -l -r --include="*.txt" FAILED {} \;` timeout-minutes: 2 - name: Complete the check - if: always() && contains(github.event.comment.body, 'run exhaustive tests') + if: always() && contains(github.event.comment.body, ${{ env.PR_COMMENT_TRIGGER_TEXT }}) run: | WORKFLOW_URL="${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" STATUS="completed" @@ -109,7 +109,7 @@ jobs: echo "SHA=$SHA" >> $GITHUB_ENV - name: Add a check to the PR id: add-check - if: contains(github.event.comment.body, 'run exhaustive tests') + if: contains(github.event.comment.body, ${{ env.PR_COMMENT_TRIGGER_TEXT }}) run: | WORKFLOW_URL="${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" echo $WORKFLOW_URL @@ -136,7 +136,7 @@ jobs: CC: clang CXX: clang++ - name: Complete the check - if: always() && contains(github.event.comment.body, 'run exhaustive tests') + if: always() && contains(github.event.comment.body, ${{ env.PR_COMMENT_TRIGGER_TEXT }}) run: | WORKFLOW_URL="${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" STATUS="completed" diff --git a/docs/userguide/dev/ci.md b/docs/userguide/dev/ci.md index 57564e22dcb2..3eccfe8256fc 100644 --- a/docs/userguide/dev/ci.md +++ b/docs/userguide/dev/ci.md @@ -117,3 +117,16 @@ because if a PR does not include ICU4J code changes, the workflow will not run and Github is not capable of ignoring the check in that scenario. Furthermore, workflow conditional triggers can only be triggered at the workflow level, not the job level. Open Source users can now access machines with [at least 4 cores available per job](https://github.blog/2024-01-17-github-hosted-runners-double-the-power-for-open-source/). + +### Exhaustive Tests +Exhaustive tests run tests on a larger, more complete dataset than the regular unit tests. +The larger dataset makes them run much longer than an individual unit test. +Thus, exhaustive tests are not run automatically on every PR. +They must pass before new versions of CLDR can be integrated into ICU, +which is a part of the release process. + +It may be desirable to run exhaustive tests manually on a PR for areas of code that are known to need the extra test coverage provided by exhaustive tests. + +Exhaustive tests can be triggered manually on a PR by adding a comment containing the following text. + +`run exhaustive tests`