Skip to content

Commit

Permalink
ci: generate coverage report before sonarqube
Browse files Browse the repository at this point in the history
  • Loading branch information
Hertzole committed Jan 10, 2025
1 parent b74b895 commit bee4bf6
Showing 1 changed file with 19 additions and 19 deletions.
38 changes: 19 additions & 19 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,27 +93,14 @@ jobs:
dotnet-version: |
8.x
- name: Install Java
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '21'
# - name: Install Java
# uses: actions/setup-java@v4
# with:
# distribution: 'temurin'
# java-version: '21'

- name: Install scanner
run: dotnet tool install dotnet-sonarscanner --tool-path . --version 6.0.0

- name: Activate Unity
continue-on-error: true
env:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
run: |
echo "$UNITY_LICENSE" | tr -d '\r' > License.ulf
unity-editor -nographics -logFile /dev/stdout -manualLicenseFile License.ulf -quit
- name: Generate Solution
run: |
unity-editor -nographics -logFile /dev/stdout -customBuildName scriptable-values -projectPath . -executeMethod Packages.Rider.Editor.RiderScriptEditor.SyncSolution -quit
ls
run: dotnet tool install dotnet-sonarscanner --tool-path .

# Download the coverage results
- name: Download coverage results
Expand All @@ -135,6 +122,19 @@ jobs:
name: coverage-report
path: CoverageReport

- name: Activate Unity
continue-on-error: true
env:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
run: |
echo "$UNITY_LICENSE" | tr -d '\r' > License.ulf
unity-editor -nographics -logFile /dev/stdout -manualLicenseFile License.ulf -quit
- name: Generate Solution
run: |
unity-editor -nographics -logFile /dev/stdout -customBuildName scriptable-values -projectPath . -executeMethod Packages.Rider.Editor.RiderScriptEditor.SyncSolution -quit
ls
# The test results have a different path than what SonarQube can read.
# We need to remove the github/workspace/ path.
- name: Fix paths
Expand Down

0 comments on commit bee4bf6

Please sign in to comment.