chore(ci): upload/download coverage reports

Signed-off-by: Ricardo Arturo Cabral Mejía <me@ricardocabral.io>
This commit is contained in:
Ricardo Arturo Cabral Mejía 2022-11-17 18:04:41 -05:00
parent 92ab264bea
commit a1236f1023

View File

@ -53,7 +53,11 @@ jobs:
- name: Run coverage for unit tests
run: npm run cover:unit
if: ${{ always() }}
continue-on-error: true
- uses: actions/upload-artifact@v3
name: Upload coverage report for unit tests
if: ${{ always() }}
with:
path: .coverage/*/lcov.info
- name: Coveralls
uses: coverallsapp/github-action@master
if: ${{ always() }}
@ -93,8 +97,11 @@ jobs:
flag-name: Integration
parallel: true
github-token: ${{ secrets.GITHUB_TOKEN }}
continue-on-error: true
- uses: actions/upload-artifact@v3
name: Upload coverage report for integration tests
if: ${{ always() }}
with:
path: .coverage/*/lcov.info
sonarcloud:
name: Sonarcloud
needs: [test-units-and-cover, test-integrations-and-cover]
@ -103,6 +110,11 @@ jobs:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/download-artifact@v3
name: Download unit & integration coverage reports
with:
path: .coverage
- run: ls -Rl .coverage
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@master
env: