-
Notifications
You must be signed in to change notification settings - Fork 15
68 lines (55 loc) · 1.5 KB
/
ci.yaml
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: CI
on: [push, pull_request]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup Python 3.10.4
uses: actions/setup-python@v4
with:
python-version: 3.10.4
- uses: pre-commit/[email protected]
tests:
runs-on: ubuntu-latest
timeout-minutes: 120
strategy:
fail-fast: false
matrix:
name:
- token
- gauge
- pools/exchange
- pools/general
- pools/liquidity
- pools/meta
- pools/oracle
- factory
steps:
- uses: actions/checkout@v3
- name: Cache Compiler Installations
uses: actions/cache@v3
with:
path: ~/.vvm
key: compiler-cache
- name: Setup Python 3.10.4
uses: actions/setup-python@v4
with:
python-version: 3.10.4
- name: Install Requirements
run: |
pip install poetry==1.8.3
poetry config virtualenvs.in-project true
poetry install --no-interaction --without dev
- name: Run Tests
env:
WEB3_PROVIDER_URL: ${{ secrets.WEB3_PROVIDER_URL }}
run: |
source .venv/bin/activate
if [[ ${{ matrix.name }} == "pools/oracle" ]]; then
pytest --numprocesses=auto --dist=loadscope tests/${{ matrix.name }}/
else
pytest --numprocesses=auto tests/${{ matrix.name }}/
fi