Skip to content

Commit

Permalink
Add tests to sonarqube
Browse files Browse the repository at this point in the history
  • Loading branch information
oveldman committed Feb 4, 2024
1 parent 540f498 commit 2d522eb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/sonarqube.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,9 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: |
dotnet-sonarscanner begin /k:"oveldman_MadWorldVPS" /o:"oveldman" /d:sonar.login="${{ secrets.SONAR_TOKEN }}" /d:sonar.host.url="https://sonarcloud.io" /d:sonar.projectBaseDir="/home/runner/work/MadWorldVPS/MadWorldVPS"
dotnet-sonarscanner begin /k:"oveldman_MadWorldVPS" /o:"oveldman" /d:sonar.login="${{ secrets.SONAR_TOKEN }}" /d:sonar.host.url="https://sonarcloud.io" /d:sonar.projectBaseDir="/home/runner/work/MadWorldVPS/MadWorldVPS" /d:sonar.cs.opencover.reportsPaths=TestResults/*/coverage.opencover.xml /d:sonar.coverage.exclusions="**Test*.cs"
dotnet workload restore ./MadWorld/MadWorld.sln;
dotnet restore ./MadWorld/MadWorld.sln;
dotnet build ./MadWorld/MadWorld.sln --no-restore -c Release;
dotnet test ./MadWorld/MadWorld.sln --no-build --no-restore -c Release --blame-hang-timeout 5min --collect:"XPlat Code Coverage" --results-directory TestResults/ -- DataCollectionRunSettings.DataCollectors.DataCollector.Configuration.Format=opencover;
dotnet-sonarscanner end /d:sonar.login="${{ secrets.SONAR_TOKEN }}"

0 comments on commit 2d522eb

Please sign in to comment.