- # - name: pnpm coverage
- # if: "github.repository == 'sap/e-mobility-charging-stations-simulator' && matrix.os == 'ubuntu-latest' && matrix.node == '18.x'"
- # run: pnpm coverage
- # - name: SonarCloud Scan
- # if: "github.repository == 'sap/e-mobility-charging-stations-simulator' && matrix.os == 'ubuntu-latest' && matrix.node == '18.x'"
- # uses: sonarsource/sonarcloud-github-action@v1.9.1
- # with:
- # projectBaseDir: ui/web
- # env:
- # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
- # SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
- build-docker:
+ - name: pnpm coverage
+ if: ${{ github.repository == 'sap/e-mobility-charging-stations-simulator' && matrix.os == 'ubuntu-latest' && matrix.node == '20.x' }}
+ run: pnpm coverage
+ - name: SonarCloud Scan
+ if: ${{ needs.check-secrets.outputs.sonar-token-exists == 'true' && github.repository == 'sap/e-mobility-charging-stations-simulator' && matrix.os == 'ubuntu-latest' && matrix.node == '20.x' }}
+ uses: sonarsource/sonarcloud-github-action@v2.0.2
+ with:
+ projectBaseDir: ui/web
+ env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
+ build-docker-image: