-
Notifications
You must be signed in to change notification settings - Fork 41
40 lines (33 loc) · 980 Bytes
/
test-core.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
name: Run Tests for Core
on: pull_request
jobs:
test-core:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: ["16.x", "18.x", "20.x"]
steps:
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Checkout code
uses: actions/checkout@v4
- name: Cache node_modules
uses: actions/cache@v3
with:
path: node_modules
key: ${{ runner.os }}-node-${{ hashFiles('package-lock.json') }}
- name: Install dependencies
run: npm ci
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
- name: Build
run: npm run build:core
- name: Test
timeout-minutes: 15
run: |
nohup sh -c "anvil -p 8545 > /dev/null 2>&1" < /dev/null &
nohup sh -c "anvil -p 8546 > /dev/null 2>&1" < /dev/null &
sleep 5
npm run test:core