Skip to content

Commit

Permalink
feature: split sonar action from pr action
Browse files Browse the repository at this point in the history
  • Loading branch information
ds-lcapellino committed Oct 17, 2024
1 parent 6ec8782 commit e2af543
Showing 1 changed file with 12 additions and 28 deletions.
40 changes: 12 additions & 28 deletions .github/workflows/pull-request_backend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,16 +71,20 @@ jobs:

- name: Run unit & integration tests
run: mvn -pl tx-models,tx-backend,tx-coverage -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn -B verify
- name: Upload integration test results
uses: actions/upload-artifact@v3

- name: Publish integration test results
uses: EnricoMi/publish-unit-test-result-action@v2
if: always()
with:
name: integration-test-results
path: "${{ github.workspace }}/tx-backend/target/failsafe-reports"
- name: Upload unit test results
uses: actions/upload-artifact@v3
files: "${{ github.workspace }}/tx-backend/target/failsafe-reports/TEST-*.xml"
check_name: "Integration Test Results"

- name: Publish unit test results
uses: EnricoMi/publish-unit-test-result-action@v2
if: always()
with:
name: unit-tests-results
path: "**/surefire-reports/"
files: "**/surefire-reports/TEST-*.xml"
check_name: "Unit Test Results"

Sonar:
needs: Test
Expand All @@ -96,26 +100,6 @@ jobs:
java-version: '${{ env.JAVA_VERSION }}'
distribution: 'temurin'
cache: 'maven'
- name: Download integration-test-results
uses: actions/download-artifact@v3
with:
name: integration-test-results
- name: Download unit-tests-results
uses: actions/download-artifact@v3
with:
name: unit-tests-results

- name: Publish integration test results
uses: EnricoMi/publish-unit-test-result-action@v2
with:
files: "**/integration-test-results/TEST-*.xml"
check_name: "Integration Test Results"

- name: Publish unit test results
uses: EnricoMi/publish-unit-test-result-action@v2
with:
files: "**/surefire-reports/TEST-*.xml"
check_name: "Unit Test Results"

- name: Clean working directories
run: |
Expand Down

0 comments on commit e2af543

Please sign in to comment.