-
Notifications
You must be signed in to change notification settings - Fork 432
204 lines (167 loc) · 6.56 KB
/
tests.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
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
name: Tests
on:
push:
branches:
- main
pull_request:
jobs:
unit-tests:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 18.x
registry-url: https://registry.npmjs.org
- uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
run: npm install
# This is required separately from yarn test because it generates the typechain definitions
- name: Compile
run: npm run build
- name: Run unit tests
run: npm run test
env:
JSON_RPC_PROVIDER: ${{ secrets.JSON_RPC_PROVIDER }}
JSON_RPC_PROVIDER_GORLI: ${{ secrets.JSON_RPC_PROVIDER_GORLI }}
JSON_RPC_PROVIDER_OPTIMISM: ${{ secrets.JSON_RPC_PROVIDER_OPTIMISM }}
JSON_RPC_PROVIDER_ARBITRUM_ONE: ${{ secrets.JSON_RPC_PROVIDER_ARBITRUM_ONE }}
JSON_RPC_PROVIDER_POLYGON: ${{ secrets.JSON_RPC_PROVIDER_POLYGON }}
integration-tests-alpha-router-integration-mainnet-alpha-0:
name: Integration Tests - Alpha Router Integration Mainnet Alpha 0
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 18.x
registry-url: https://registry.npmjs.org
- uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
run: npm install
# This is required separately from yarn test because it generates the typechain definitions
- name: Compile
run: npm run build
- name: Run Integration tests
run: npm run integ-test -- -t 'mainnet alpha - 0'
env:
JSON_RPC_PROVIDER: ${{ secrets.JSON_RPC_PROVIDER }}
integration-tests-alpha-router-integration-mainnet-alpha-1:
name: Integration Tests - Alpha Router Integration Mainnet Alpha 1
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 18.x
registry-url: https://registry.npmjs.org
- uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
run: npm install
# This is required separately from yarn test because it generates the typechain definitions
- name: Compile
run: npm run build
- name: Run Integration tests
run: npm run integ-test -- -t 'mainnet alpha - 1'
env:
JSON_RPC_PROVIDER: ${{ secrets.JSON_RPC_PROVIDER }}
integration-tests-alpha-router-integration-mixed-routes:
name: Integration Tests - Alpha Router Integration Mixed Routes
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 18.x
registry-url: https://registry.npmjs.org
- uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
run: npm install
# This is required separately from yarn test because it generates the typechain definitions
- name: Compile
run: npm run build
- name: Run Integration tests
run: npm run integ-test -- -t 'Mixed routes'
env:
JSON_RPC_PROVIDER: ${{ secrets.JSON_RPC_PROVIDER }}
integration-tests-external-class-tests:
name: Integration Tests - External Class Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 18.x
registry-url: https://registry.npmjs.org
- uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
run: npm install
# This is required separately from yarn test because it generates the typechain definitions
- name: Compile
run: npm run build
- name: Run Integration tests
run: npm run integ-test -- -t 'external class tests'
env:
JSON_RPC_PROVIDER: ${{ secrets.JSON_RPC_PROVIDER }}
integration-tests-quote-for-other-networks:
name: Integration Tests - Quote For Other Networks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-node@v1
with:
node-version: 18.x
registry-url: https://registry.npmjs.org
- uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
run: npm install
# This is required separately from yarn test because it generates the typechain definitions
- name: Compile
run: npm run build
- name: Run Integration tests
run: npm run integ-test -- -t 'quote for other networks'
env:
JSON_RPC_PROVIDER: ${{ secrets.JSON_RPC_PROVIDER }}
JSON_RPC_PROVIDER_GORLI: ${{ secrets.JSON_RPC_PROVIDER_GORLI }}
JSON_RPC_PROVIDER_OPTIMISM: ${{ secrets.JSON_RPC_PROVIDER_OPTIMISM }}
JSON_RPC_PROVIDER_OPTIMISM_GOERLI: ${{ secrets.JSON_RPC_PROVIDER_OPTIMISM_GOERLI }}
JSON_RPC_PROVIDER_ARBITRUM_ONE: ${{ secrets.JSON_RPC_PROVIDER_ARBITRUM_ONE }}
JSON_RPC_PROVIDER_ARBITRUM_GOERLI: ${{ secrets.JSON_RPC_PROVIDER_ARBITRUM_GOERLI }}
JSON_RPC_PROVIDER_POLYGON: ${{ secrets.JSON_RPC_PROVIDER_POLYGON }}
JSON_RPC_PROVIDER_POLYGON_MUMBAI: ${{ secrets.JSON_RPC_PROVIDER_POLYGON_MUMBAI }}
JSON_RPC_PROVIDER_CELO: ${{ secrets.JSON_RPC_PROVIDER_CELO }}
JSON_RPC_PROVIDER_CELO_ALFAJORES: ${{ secrets.JSON_RPC_PROVIDER_CELO_ALFAJORES }}
JSON_RPC_PROVIDER_BNB: ${{ secrets.JSON_RPC_PROVIDER_BNB }}
JSON_RPC_PROVIDER_AVALANCHE: ${{ secrets.JSON_RPC_PROVIDER_AVALANCHE }}
JSON_RPC_PROVIDER_BASE: ${{ secrets.JSON_RPC_PROVIDER_BASE }}