File tree Expand file tree Collapse file tree 2 files changed +28
-3
lines changed
Expand file tree Collapse file tree 2 files changed +28
-3
lines changed Original file line number Diff line number Diff line change @@ -3,9 +3,10 @@ name: .NET
33on :
44 push :
55 branches : [ main ]
6+
67 pull_request :
7- branches : [ main ]
8-
8+ types : [opened, synchronize, reopened ]
9+
910 workflow_dispatch :
1011
1112jobs :
@@ -31,14 +32,33 @@ jobs:
3132
3233 - name : Test
3334 run : dotnet test /p:CollectCoverage=true /p:CoverletOutput=coverage /p:CoverletOutputFormat=opencover
35+
36+ - name : Copy coverage files
37+ run : |
38+ mkdir '${{ github.workspace }}/coverage'
39+ find . -name "*.opencover.xml" -exec sh -c 'cp "$0" "coverage/coverage-$(basename $0)"' {} \;
40+
41+ - name : List coverage files
42+ run : ls '${{ github.workspace }}/coverage/'
3443
44+ - name : SonarCloud Scan
45+ uses : sonarsource/sonarcloud-github-action@master
46+ with :
47+ args : >
48+ -Dsonar.organization=managedcode
49+ -Dsonar.projectKey=managedcode_Storage
50+ -Dsonar.token=${{ secrets.SONAR_TOKEN }}
51+ -Dsonar.cs.opencover.reportsPaths=${{ github.workspace }}/coverage/
52+ env :
53+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
54+ SONAR_TOKEN : ${{ secrets.SONAR_TOKEN }}
3555
3656 - name : NDepend
3757 uses : ndepend/ndepend-action@v1
3858 with :
3959 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
4060 license : ${{ secrets.NDEPENDLICENSE }}
41- coveragefolder : ${{ github.workspace }}/ManagedCode.Storage.IntegrationTests
61+ coveragefolder : ${{ github.workspace }}/coverage/
4262 baseline : main_recent
4363 retention-days : 15
4464 # stopIfQGFailed: true
Original file line number Diff line number Diff line change 77[ ![ nuget] ( https://github.com/managedcode/Storage/actions/workflows/nuget.yml/badge.svg?branch=main )] ( https://github.com/managedcode/Storage/actions/workflows/nuget.yml )
88[ ![ CodeQL] ( https://github.com/managedcode/Storage/actions/workflows/codeql-analysis.yml/badge.svg?branch=main )] ( https://github.com/managedcode/Storage/actions/workflows/codeql-analysis.yml )
99
10+ [ ![ Alert Status] ( https://sonarcloud.io/api/project_badges/measure?project=managedcode_Storage&metric=alert_status )] ( https://sonarcloud.io/summary/new_code?id=managedcode_Storage )
11+ [ ![ Coverage] ( https://sonarcloud.io/api/project_badges/measure?project=managedcode_Storage&metric=coverage )] ( https://sonarcloud.io/summary/new_code?id=managedcode_Storage )
12+
13+
14+
1015
1116| Version | Package | Description |
1217| ------- | ---------------------------------------------------------------------------------------------------------------------------------------| -----------------|
You can’t perform that action at this time.
0 commit comments