This commit is contained in:
Leonid Pershin
2025-10-18 04:05:16 +03:00
parent e3b6175860
commit 7ad0bc4287

View File

@@ -28,7 +28,8 @@ jobs:
dotnet tool install dotnet-sonarscanner --tool-path ~/.sonar/scanner
- name: Install dotnet-coverage
run: |
dotnet tool install --global dotnet-coverage
mkdir -p ~/.sonar/coverage
dotnet tool install dotnet-coverage --tool-path ~/.sonar/coverage
- name: Restore dependencies
run: dotnet restore --verbosity normal
- name: Build and analyze
@@ -44,6 +45,6 @@ jobs:
echo "Building project..."
dotnet build --verbosity normal --no-incremental
echo "Collecting coverage..."
dotnet-coverage collect "dotnet test" -f xml -o "coverage.xml"
~/.sonar/coverage/dotnet-coverage collect "dotnet test" -f xml -o "coverage.xml"
echo "Ending SonarQube analysis..."
~/.sonar/scanner/dotnet-sonarscanner end /d:sonar.token="${{ secrets.SONAR_TOKEN }}"