From e57bc18fb5309a9408cedafc86e605521c7a7dc8 Mon Sep 17 00:00:00 2001 From: Quake Date: Tue, 27 Feb 2024 22:28:02 +0100 Subject: [PATCH] test: use sonarcloud github action --- .github/workflows/test-build.yaml | 17 +++-------------- sonar-project.properties | 6 ++++++ 2 files changed, 9 insertions(+), 14 deletions(-) create mode 100644 sonar-project.properties diff --git a/.github/workflows/test-build.yaml b/.github/workflows/test-build.yaml index 366c7f23..a533b47b 100644 --- a/.github/workflows/test-build.yaml +++ b/.github/workflows/test-build.yaml @@ -43,23 +43,12 @@ jobs: with: java-version: 11 distribution: 'zulu' # Alternative distribution options are available. - - name: Prepare Sonarcloud Analysis + - name: Perform Sonar Scan + uses: sonarsource/sonarcloud-github-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - shell: powershell - run: > - .\.sonar\scanner\dotnet-sonarscanner begin - /k:"team-zomsa_aplib.net-demo" /o:"team-zomsa" - /d:sonar.token="${{ secrets.SONAR_TOKEN }}" - /d:sonar.host.url="https://sonarcloud.io" - /d:sonar.cs.vscoveragexml.reportsPaths=coverage.xml - - name: Run SonarCloud Analysis - env: - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - shell: powershell - run: | - .\.sonar\scanner\dotnet-sonarscanner end /d:sonar.token="${{ secrets.SONAR_TOKEN }}" + unity-test: name: Test with Unity Test Runner diff --git a/sonar-project.properties b/sonar-project.properties new file mode 100644 index 00000000..6e922959 --- /dev/null +++ b/sonar-project.properties @@ -0,0 +1,6 @@ +sonar.organization=team-zomsa +sonar.projectKey=team-zomsa_aplib.net-demo + +# relative paths to source directories. More details and properties are described +# in https://sonarcloud.io/documentation/project-administration/narrowing-the-focus/ +sonar.sources=./aplib.net-demo/ \ No newline at end of file