Sonar Analysis #200
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Sonar Analysis | |
on: | |
schedule: | |
- cron: '0 0 * * SAT' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Use Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 16.x | |
cache: 'npm' | |
- run: npm ci | |
- run: npm run build | |
- run: npm test -- --coverage | |
- name: SonarCloud Scan | |
uses: SonarSource/sonarcloud-github-action@master | |
with: | |
args: > | |
-Dsonar.organization=axaguildev | |
-Dsonar.projectKey=AxaGuilDEv_react-toolkit | |
-Dsonar.javascript.lcov.reportPaths=coverage/lcov.info | |
-Dsonar.exclusions=**/*.stories.*,**/*.spec.*,scripts/**,coverage/**,**/node_modules/**,**/dist/**,**/__mocks__/**,examples/**,storybook/**,jest.config.js,gulpfile.js,**/*.scss,**/__snapshots__/**,**/*.svg,**/*.txt,**/*.woff,**/*.ico | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} |