@@ -23,25 +23,27 @@ jobs:
2323 id-token : write # Required for Vault OIDC authentication
2424 contents : write # Required for repository access and tagging
2525 outputs :
26- build-number : ${{ steps.build-gradle.outputs.BUILD_NUMBER }}
26+ build-number : ${{ steps.build-step.outputs.BUILD_NUMBER }}
27+ deployed : ${{ steps.build-step.outputs.deployed }}
2728 steps :
2829 - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
2930 - uses : jdx/mise-action@5ac50f778e26fac95da98d50503682459e86d566 # v3.2.0
3031 with :
3132 version : 2025.7.12
3233 - uses : SonarSource/ci-github-actions/build-gradle@v1
33- id : build-gradle
34+ id : build-step
3435 with :
3536 deploy-pull-request : true
3637 artifactory-reader-role : private-reader # Override for public repo using private access
3738 artifactory-deployer-role : qa-deployer # Override for public repo using private access
3839
3940 qa :
4041 needs : [build]
42+ if : ${{ needs.build.outputs.deployed }}
4143 runs-on : github-ubuntu-latest-s # Public repository runner
4244 permissions :
4345 id-token : write # Required for Vault OIDC authentication
44- contents : write # Required for repository access
46+ contents : read # Required for repository access
4547 strategy :
4648 fail-fast : false
4749 matrix :
@@ -51,61 +53,54 @@ jobs:
5153 item :
5254 - { suite: "plugin", sq_version: "DEV", submodules: false}
5355 - { suite: "plugin", sq_version: "LATEST_RELEASE", submodules: false}
54- - { suite: "ruling", sq_version: "LATEST_RELEASE", submodules: true }
56+ - { suite: "ruling", sq_version: "LATEST_RELEASE" }
5557 name : " QA Tests [${{ matrix.item.suite }}] - SQ : ${{ matrix.item.sq_version }}"
5658 steps :
5759 - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
5860 with :
59- submodules : ${{ matrix.item.submodules }}
61+ submodules : ${{ matrix.item.suite == 'ruling' }}
6062 - name : Remove kotlin ITs as they are not relevant for ruling tests (and cause issues with wrapper validation)
61- if : ${{ matrix.item.submodules }}
63+ if : ${{ matrix.item.suite == 'ruling' }}
6264 run : rm -r ./its/sources/kotlin
6365 - uses : jdx/mise-action@5ac50f778e26fac95da98d50503682459e86d566 # v3.2.0
6466 with :
65- cache_save : false
6667 version : 2025.7.12
6768 - name : Get GitHub Token for QA Licenses
6869 id : secrets
6970 uses : SonarSource/vault-action-wrapper@v3
7071 with :
71- # TODO Remove artifactory token when build-gradle provides it
7272 secrets : |
7373 development/github/token/licenses-ro token | GITHUB_TOKEN;
7474 development/artifactory/token/{REPO_OWNER_NAME_DASH}-private-reader access_token | ARTIFACTORY_ACCESS_TOKEN;
7575 - name : Configure Gradle
76- uses : SonarSource/ci-github-actions/build-gradle@v1 # TODO When config-gradle is released, use it and remove the gradle-args below
76+ uses : SonarSource/ci-github-actions/build-gradle@v1
7777 with :
7878 gradle-args : " -x build -x sonar -x artifactoryPublish" # Skip everything to only configure Gradle and Artifactory access
79- artifactory-reader-role : private-reader # Override for public repo using private access
80- artifactory-deployer-role : qa-deployer # TODO Should not be needed for config-gradle
79+ artifactory-reader-role : private-reader
80+ artifactory-deployer-role : qa-deployer
8181 - name : Run QA Tests
8282 env :
8383 GITHUB_TOKEN : ${{ fromJSON(steps.secrets.outputs.vault).GITHUB_TOKEN }}
8484 ARTIFACTORY_ACCESS_TOKEN : ${{ fromJSON(steps.secrets.outputs.vault).ARTIFACTORY_ACCESS_TOKEN }}
8585 SUITE : ${{ matrix.item.suite }}
8686 SQ_VERSION : ${{ matrix.item.sq_version }}
87- BUILD_NUMBER : ${{ needs.build.outputs.build-number }}
8887 run : |
8988 ./gradlew ":its:${SUITE}:test" --project-prop ${SUITE} \
9089 "-Dsonar.runtimeVersion=${SQ_VERSION}" \
9190 "-Dorchestrator.artifactory.accessToken=${ARTIFACTORY_ACCESS_TOKEN}" \
9291 "-DbuildNumber=${BUILD_NUMBER}" \
9392 --info --stacktrace --console plain --no-daemon --build-cache
9493 promote :
94+ name : Promote
9595 needs :
9696 - build
9797 - qa
9898 runs-on : github-ubuntu-latest-s # Public repository runner
99- name : Promote
99+ if : ${{ needs.build.outputs.deployed }}
100100 permissions :
101101 id-token : write # Required for Vault OIDC authentication
102102 contents : write # Required for repository access and tagging
103103 steps :
104- - uses : actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
105- - uses : jdx/mise-action@5ac50f778e26fac95da98d50503682459e86d566 # v3.2.0
106- with :
107- cache_save : false
108- version : 2025.7.12
109104 - uses : SonarSource/ci-github-actions/promote@v1
110105 with :
111106 promote-pull-request : true # Enable PR artifact promotion
0 commit comments