-
Notifications
You must be signed in to change notification settings - Fork 2.2k
68 lines (56 loc) · 1.7 KB
/
protocol.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
name: Protocol
on:
push:
branches: [main]
paths:
- "packages/protocol/**"
pull_request:
paths:
- "packages/protocol/**"
jobs:
build:
runs-on: [taiko-runner]
steps:
- name: Cancel previous runs
uses: styfle/cancel-workflow-action@0.12.1
with:
access_token: ${{ github.token }}
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly-2cb875799419c907cc3709e586ece2559e6b340e
- name: Install pnpm dependencies
uses: ./.github/actions/install-pnpm-dependencies
- name: Check formatting
working-directory: ./packages/protocol
run: forge fmt --check
- name: Unit Tests
working-directory: ./packages/protocol
run: pnpm clean && pnpm test
- name: Generate Genesis
working-directory: ./packages/protocol
run: pnpm test:genesis
# TODO: CompilerError: Stack too deep
# - name: Test Coverage
# working-directory: ./packages/protocol
# run: pnpm test:coverage
- name: Run snapshot (foundry)
working-directory: ./packages/protocol
run: pnpm snapshot
- name: Deploy L1 Contracts
working-directory: ./packages/protocol
run: |
anvil --hardfork cancun &
while ! nc -z localhost 8545; do
sleep 1
done
pnpm test:deploy
# - name: Upload coverage to Codecov
# uses: codecov/codecov-action@v3
# with:
# directory: ./packages/protocol/coverage
# flags: protocol