-
Notifications
You must be signed in to change notification settings - Fork 8
67 lines (57 loc) · 1.84 KB
/
pytest.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
name: PyTest
on:
pull_request:
branch: master
paths:
- '**.py'
- '**/pytest.yaml'
- 'pyproject.toml'
- 'poetry.lock'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest, macos-latest, windows-latest ]
pyversion: [ "3.8", "3.9", "3.10", "3.11", "3.12" ]
provider: [ "TENDERLY_PROVIDER", "LLAMA_ETH_RPC", "INFURA_PROVIDER", "ALCHEMY_PROVIDER", "RETH_PROVIDER", "CHAINSTACK_PROVIDER" ]
include:
- os: ubuntu-latest
path: ~/.cache/pip
- os: macos-latest
path: ~/Library/Caches/pip
- os: windows-latest
path: ~\AppData\Local\pip\Cache
exclude:
# gh runner throws "Error: Version ${{ matrix.pyversion }} with arch arm64 not found"
- os: macos-latest
pyversion: "3.8"
- os: macos-latest
pyversion: "3.9"
steps:
- name: Check out repository code
uses: actions/[email protected]
with:
persist-credentials: false
- name: Setup Python (faster than using Python container)
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.pyversion }}
- name: Install Poetry
uses: snok/install-poetry@v1
- name: Install Dependencies
run: poetry install --no-interaction
- name: Setup brownie networks
run: |
poetry run brownie networks modify mainnet host=${{ secrets[matrix.provider] }}
continue-on-error: true
- name: Run test suite
env:
PYTEST_NETWORK: mainnet
ETHERSCAN_TOKEN: ${{ secrets.ETHERSCAN_TOKEN }}
run: |
poetry run pytest --asyncio-task-timeout=3600