Skip to content

Commit

Permalink
Update Github Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
Stummi committed Mar 6, 2025
1 parent 39f3718 commit efbfb00
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 53 deletions.
52 changes: 0 additions & 52 deletions .github/workflows/scorecard.yml

This file was deleted.

28 changes: 27 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,30 @@ jobs:
go-version-file: 'go.mod'

- name: Test
run: go test ./...
run: go test -covermode=atomic -coverpkg=./... -coverprofile=test.cov -v ./...

- name: upload coverage data
uses: actions/upload-artifact@v4
with:
name: test.cov
path: test.cov
retention-days: 1

sonar:
name: Run SonarCloud Analysis
runs-on: ubuntu-22.04
needs: test
steps:
- name: Check out code
uses: actions/checkout@v4
- name: download coverage data from GitHub storage
uses: actions/download-artifact@v4
with:
path: cov/
merge-multiple: true
- name: SonarCloud Scan
uses: sonarsource/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONARCLOUD_TOKEN }}

15 changes: 15 additions & 0 deletions sonar-project.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
sonar.organization=staffbase
sonar.projectKey=com.staffbase:gosaml2
sonar.projectDescription=Our very own gosaml2 fork
sonar.links.homepage=https://github.com/Staffbase/gosaml2
sonar.sourceEncoding=UTF-8

sonar.scm.provider=git

sonar.sources=.
sonar.exclusions=**/*_test.go

sonar.tests=.
sonar.test.inclusions=**/*_test.go

sonar.go.coverage.reportPaths=cov/*.cov

0 comments on commit efbfb00

Please sign in to comment.