File tree Expand file tree Collapse file tree 1 file changed +41
-0
lines changed
Expand file tree Collapse file tree 1 file changed +41
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Sonar
2+
3+ on :
4+ push :
5+ branches : [ master ]
6+ pull_request :
7+ branches : [ master ]
8+
9+ jobs :
10+ build :
11+
12+ runs-on : ubuntu-latest
13+
14+ steps :
15+ - uses : actions/checkout@v2
16+ - name : Use Node.js 13
17+ uses : actions/setup-node@v1
18+ with :
19+ node-version : 13
20+ - name : Build with npm
21+ run : |
22+ npm ci
23+ npm run build --if-present
24+ npm test
25+ npm run coverage
26+ - name : SonarCloud
27+ uses : sonarsource/sonarcloud-github-action@master
28+ env :
29+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
30+ SONAR_TOKEN : ${{ secrets.SONAR_TOKEN }}
31+ with :
32+ args : >
33+ -Dsonar.organization=mastercard
34+ -Dsonar.projectName=oauth1-signer-nodejs
35+ -Dsonar.projectKey=Mastercard_oauth1-signer-nodejs
36+ -Dsonar.sources=./src
37+ -Dsonar.tests=./test
38+ -Dsonar.coverage.jacoco.xmlReportPaths=test-results.xml
39+ -Dsonar.javascript.lcov.reportPaths=.nyc_output/coverage.lcov
40+ -Dsonar.host.url=https://sonarcloud.io
41+ -Dsonar.login=${{ secrets.SONAR_TOKEN }}
You can’t perform that action at this time.
0 commit comments