-
Notifications
You must be signed in to change notification settings - Fork 12
51 lines (49 loc) · 1.47 KB
/
ci-merge.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
name: ci-merge
on:
push:
branches: ["main"]
workflow_dispatch:
branches: ["main"]
jobs:
ci:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x]
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}
- uses: actions/cache@v2
with:
path: "**/node_modules"
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
- name: Install and build
run: yarn --frozen-lockfile
- name: Unit tests
run: yarn test:ci
- name: Process Test Results
uses: dorny/test-reporter@v1
with:
name: Jest Tests
path: "junit.xml"
reporter: jest-junit
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v2
with:
files: ./coverage/coverage-final.json
verbose: true
- name: Upload coverage to Code Climate
uses: paambaati/[email protected]
env:
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
with:
coverageLocations: |
${{ github.workspace }}/coverage/lcov.info:lcov
- name: Upload coverage to Codacy
uses: codacy/[email protected]
with:
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
coverage-reports: ./coverage/lcov.info