-
Notifications
You must be signed in to change notification settings - Fork 5
49 lines (38 loc) · 1.13 KB
/
js-ci.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
name: '[js] CI'
on:
pull_request:
types: [opened, synchronize, reopened, labeled]
branches: [master]
paths:
- 'js/**'
- 'package.json'
jobs:
test:
runs-on: ubuntu-22.04
steps:
- name: Cancel previous workflow runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout
uses: actions/checkout@v4
- name: 'Install: NodeJS 20.x'
uses: actions/setup-node@v4
with:
node-version: 20.x
- name: 'Install: dependencies'
run: yarn install
- name: 'Prepare: build all'
run: yarn build
- name: 'Prepare: fmt'
run: yarn lint
- name: 'Prepare: download Gear node'
run: |
wget -O ./gear https://github.com/gear-tech/gear/releases/download/build/gear
chmod +x gear
- name: 'Prepare: run Gear node'
run: nohup ./gear --dev --execution=wasm --tmp --unsafe-rpc-external --rpc-methods Unsafe --rpc-cors all &
- name: 'Prepare: sleep 3 min'
run: sleep 180
- name: 'Test: run'
run: yarn test