forked from dexloom/loom
-
Notifications
You must be signed in to change notification settings - Fork 0
84 lines (71 loc) · 2.11 KB
/
rust.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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
name: CI
on:
push:
branches:
- main
pull_request_target:
types: [opened,synchronize,reopened]
branches:
- main
env:
CARGO_TERM_COLOR: always
jobs:
tests-stable:
name: Tests (Stable)
runs-on: ubuntu-latest
environment: default
env:
ETH_MAINNET_HTTP: ${{ secrets.MAINNET_HTTP }}
ETH_MAINNET_WS: ${{ secrets.MAINNET_WS }}
RUST_LOG: info
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Add private.rs dummy file
run: 'echo "pub const KEY_ENCRYPTION_PWD: [u8; 16] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];" > crates/defi-entities/src/private.rs'
- name: Install toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
override: true
- name: Install Anvil
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly
- name: Run cargo test
run: make test
fmt:
runs-on: ubuntu-latest
environment: default
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Add private.rs dummy file
run: 'echo "pub const KEY_ENCRYPTION_PWD: [u8; 16] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];" > crates/defi-entities/src/private.rs'
- name: Install toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
components: rustfmt
override: true
- name: Run cargo fmt
run: make fmt-check
clippy:
runs-on: ubuntu-latest
environment: default
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Add private.rs dummy file
run: 'echo "pub const KEY_ENCRYPTION_PWD: [u8; 16] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];" > crates/defi-entities/src/private.rs'
- name: Install toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
components: clippy
override: true
- name: Run cargo clippy
run: make clippy