-
Notifications
You must be signed in to change notification settings - Fork 1
96 lines (96 loc) · 2.83 KB
/
coverage.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
name: Code Coverage
on:
push:
branches:
- main
jobs:
test-alcs-frontend:
defaults:
run:
working-directory: alcs-frontend
strategy:
matrix:
platform: [ubuntu-latest]
node: ["20"]
name: Coverage Report ALCS Frontend - ${{ matrix.node }}/${{ matrix.platform }}
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@master
- uses: actions/setup-node@master
with:
node-version: ${{ matrix.node }}
- run: npm install
- run: npm run build
- run: npm run test:cov
- if: matrix.node == '20'
uses: actions/upload-artifact@v4
with:
name: coverage-alcs-frontend
path: ${{ github.workspace }}/alcs-frontend/coverage
retention-days: 1
if-no-files-found: error
test-portal-frontend:
defaults:
run:
working-directory: portal-frontend
strategy:
matrix:
platform: [ubuntu-latest]
node: ["20"]
name: Coverage Report Portal Frontend - ${{ matrix.node }}/${{ matrix.platform }}
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@master
- uses: actions/setup-node@master
with:
node-version: ${{ matrix.node }}
- run: npm install
- run: npm run build
- run: npm run test:cov
- if: matrix.node == '20'
uses: actions/upload-artifact@v4
with:
name: coverage-portal-frontend
path: ${{ github.workspace }}/portal-frontend/coverage
retention-days: 1
if-no-files-found: error
test-api:
defaults:
run:
working-directory: services
strategy:
matrix:
platform: [ubuntu-latest]
node: ["20"]
name: Coverage Report API - ${{ matrix.node }}/${{ matrix.platform }}
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@master
- uses: actions/setup-node@master
with:
node-version: ${{ matrix.node }}
- run: npm install
- run: npm run build
- run: npm run test:cov
- if: matrix.node == '20'
uses: actions/upload-artifact@v4
with:
name: coverage-api
path: ${{ github.workspace }}/services/coverage
if-no-files-found: error
retention-days: 1
coverage:
needs: [test-alcs-frontend, test-portal-frontend, test-api]
name: Publish Coverage Reports
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/download-artifact@v4
- run: find .
- uses: paambaati/codeclimate-action@v3.0.0
env:
CC_TEST_REPORTER_ID: 3afdaf9ea2909da512cd49bd70113304aad3f6a3b84c4f1047c8ae0111817ab1
with:
coverageLocations: |
${{ github.workspace }}/**/lcov.info:lcov
prefix: ${{ github.workplace }}