-
Notifications
You must be signed in to change notification settings - Fork 1
31 lines (31 loc) · 1.17 KB
/
sonarqube-analysis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
name: Sonarqube Analyze
on:
push:
branches:
- main
pull_request:
types: [opened, synchronize, reopened]
jobs:
sonarcloud:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Setup .NET Core 7.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: '7.0.x'
- name: SonarScanner for .NET Core with pull request decoration support
uses: highbyte/sonarscan-dotnet@v2.2.1
with:
sonarProjectKey: qatoolkit_qatoolkit-source-swagger-net
sonarProjectName: qatoolkit_qatoolkit-source-swagger-net
sonarOrganization: qatoolkit
dotnetBuildArguments: ./src/QAToolKit.Source.Swagger/QAToolKit.Source.Swagger.csproj
dotnetTestArguments: ./src/QAToolKit.Source.Swagger.Test/QAToolKit.Source.Swagger.Test.csproj /p:CollectCoverage=true /p:CoverletOutputFormat=opencover
sonarBeginArguments: /d:sonar.verbose="true" /d:sonar.language="cs" /d:sonar.cs.opencover.reportsPaths="**/*.opencover.xml"
sonarHostname: "https://sonarcloud.io"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}