Skip to content

Commit

Permalink
Dotnet coverage installation
Browse files Browse the repository at this point in the history
  • Loading branch information
Apolixit committed Jul 30, 2023
1 parent c23421e commit 94de2da
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,13 +60,18 @@ jobs:
run: |
New-Item -Path .\.sonar\scanner -ItemType Directory
dotnet tool update dotnet-sonarscanner --tool-path .\.sonar\scanner
- name: Install Dotnet coverage
shell: powershell
run: |
dotnet tool install --global dotnet-coverage
- name: Build and analyze
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
shell: powershell
run: |
dotnet tool install dotnet-coverage
.\.sonar\scanner\dotnet-sonarscanner begin /k:"SubstrateGaming_Substrate.NET.Metadata" /o:"substrategaming" /d:sonar.token="${{ secrets.SONAR_TOKEN }}" /d:sonar.host.url="https://sonarcloud.io" /d:sonar.cs.vscoveragexml.reportsPaths=coverage.xml
dotnet build
dotnet-coverage collect "dotnet test" -f xml -o "coverage.xml"
Expand Down

0 comments on commit 94de2da

Please sign in to comment.