From 3f36833f08b6bb6939df754a93f1722976570ed4 Mon Sep 17 00:00:00 2001 From: Sergejs Luhmirins Date: Tue, 13 Jan 2026 16:19:57 +0200 Subject: [PATCH 1/4] MS-1288 Cancel in-progress runs when a new commit is pushed to the PR --- .github/workflows/pr-checks.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/pr-checks.yml b/.github/workflows/pr-checks.yml index 06843b40fb..9512bd0839 100644 --- a/.github/workflows/pr-checks.yml +++ b/.github/workflows/pr-checks.yml @@ -8,6 +8,11 @@ on: # this checks should be triggered on pull request, before deployments, and m workflow_call: workflow_dispatch: +# Cancel in-progress runs when a new commit is pushed to the PR +concurrency: + group: pr-checks-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: core-unit-tests: name: Core Unit Tests From 37d4b2bbc083177663da7904d513963df2a7097c Mon Sep 17 00:00:00 2001 From: Sergejs Luhmirins Date: Tue, 13 Jan 2026 16:27:28 +0200 Subject: [PATCH 2/4] MS-1288 Update the PR-check pull_request trigger --- .github/workflows/pr-checks.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/pr-checks.yml b/.github/workflows/pr-checks.yml index 9512bd0839..9ad49b46ff 100644 --- a/.github/workflows/pr-checks.yml +++ b/.github/workflows/pr-checks.yml @@ -5,6 +5,14 @@ on: # this checks should be triggered on pull request, before deployments, and m pull_request: paths-ignore: - 'infra/resources/src/main/res/**' + - '**.md' + types: + # Default types of PR triggers + - opened + - reopened + - synchronize + # Ensures that Sonar check are run once PR is ready + - ready_for_review workflow_call: workflow_dispatch: From 5fd015cf0943ddc5457c030f13fb428b66ca36da Mon Sep 17 00:00:00 2001 From: Sergejs Luhmirins Date: Tue, 13 Jan 2026 17:27:11 +0200 Subject: [PATCH 3/4] MS-1280 Run all test tasks in a single gradle command --- .github/workflows/reusable-run-unit-tests.yml | 25 +++++++++++-------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/.github/workflows/reusable-run-unit-tests.yml b/.github/workflows/reusable-run-unit-tests.yml index aebbfb5a30..fea7c21877 100644 --- a/.github/workflows/reusable-run-unit-tests.yml +++ b/.github/workflows/reusable-run-unit-tests.yml @@ -60,20 +60,23 @@ jobs: - name: Run tests run: | # Get the modules array from the previous step - modules_array=("${{ steps.create-modules-array.outputs.modules_array}}") - modules_array=(${modules_array// / }) - # Iterate over the array + modules_array=(${{ steps.create-modules-array.outputs.modules_array }}) + # Transform input list into a single string of gradle tasks + TASKS="" for module in "${modules_array[@]}"; do - echo -e "\n\n" - echo "==========================================" - echo "==========================================" - echo " Test $module" - echo "==========================================" - echo "==========================================" - echo -e "\n\n" - ./gradlew $module:jacocoTestReport + if [ -n "$module" ]; then + TASKS="$TASKS $module:jacocoTestReport" + fi done + echo -e "\n\n" + echo "==========================================" + echo "==========================================" + echo "Executing Gradle tasks: $TASKS" + echo "==========================================" + echo "==========================================" + echo -e "\n\n" + ./gradlew $TASKS --continue --no-daemon - name: Upload Folders uses: actions/upload-artifact@v6 with: From c140d48a3eb53289d64b7ebd92a80534cc5e036b Mon Sep 17 00:00:00 2001 From: Sergejs Luhmirins Date: Tue, 13 Jan 2026 17:29:42 +0200 Subject: [PATCH 4/4] MS-12188 Do not run sonar checks if PR is in draft --- .github/workflows/pr-checks.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/pr-checks.yml b/.github/workflows/pr-checks.yml index 9ad49b46ff..1bfb788fb8 100644 --- a/.github/workflows/pr-checks.yml +++ b/.github/workflows/pr-checks.yml @@ -159,3 +159,5 @@ jobs: fingerprint-unit-tests, testing-tools ] uses: ./.github/workflows/reusable-sonar-scan.yml + # Only run if the PR ready for review or triggered manually + if: github.event.pull_request.draft == false || github.event_name == 'workflow_dispatch'