-
Notifications
You must be signed in to change notification settings - Fork 11
35 lines (28 loc) · 863 Bytes
/
test.yaml
File metadata and controls
35 lines (28 loc) · 863 Bytes
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
name: Test
on: [push, pull_request]
jobs:
unit-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- uses: actions/setup-node@v4
with:
node-version: 18
- name: restore lerna
uses: actions/cache@v4
with:
path: '**/node_modules'
key: ${{ runner.os }}-${{ hashFiles('**/package-lock.json') }}
- name: Install project dependencies and build
run: npm i
- name: Install capsule
uses: actions-rs/install@v0.1
with:
crate: ckb-capsule
version: latest
- name: Build packages
run: npm run build
- name: Run test with coverage
run: npx lerna run test -- --coverage
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4