-
Notifications
You must be signed in to change notification settings - Fork 1
51 lines (40 loc) · 1.09 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
name: CI Workflow
on: [push, pull_request]
jobs:
# Linting with Pre-commit
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup Python 3.12.6
uses: actions/setup-python@v4
with:
python-version: 3.12.6
# Run pre-commit hooks (e.g., black, flake8, isort)
- uses: pre-commit/[email protected]
# Test runs
tests:
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v3
# install poetry to allow cacheing
- name: Install poetry
run: pipx install poetry
- name: Setup Python 3.12.6
uses: actions/setup-python@v5
with:
python-version: 3.12.6
cache: 'poetry'
- name: Install Requirements
run: |
poetry config virtualenvs.in-project true
poetry install
- name: Run Tests
env:
ETH_RPC_URL: ${{ secrets.ETH_RPC_URL }}
ETHERSCAN_API_KEY: ${{ secrets.ETHERSCAN_API_KEY }}
run: |
poetry run pytest -n auto