forked from OpenZeppelin/nile
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
76 lines (69 loc) · 1.68 KB
/
tox.ini
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
[tox]
minversion = 3.15
envlist = default
isolated_build = True
[testenv]
description = Invoke pytest to run automated tests
setenv =
TOXINIDIR = {toxinidir}
TEST_KEY = 1234
TEST_KEY_2 = 4321
passenv =
HOME
extras =
testing
deps =
cairo-lang==0.10.0
starknet-devnet==0.3.1
# See https://github.com/starkware-libs/cairo-lang/issues/52
marshmallow-dataclass==8.5.3
commands =
pytest {posargs}
[testenv:unit]
description = Invoke pytest to run unit tests
commands =
pytest -m "not end_to_end" {posargs}
[testenv:coverage]
description = Invoke pytest to run unit tests and coverage
commands =
coverage run -m pytest -m "not end_to_end" {posargs}
[testenv:build]
description = Build the package in isolation according to PEP517, see https://github.com/pypa/build
skip_install = True
changedir = {toxinidir}
deps =
build[virtualenv]
twine
commands =
python -m build . -o dist
python -m twine check --strict dist/*
[testenv:clean]
description = Remove old distribution files and temporary build artifacts (./build and ./dist)
skip_install = True
changedir = {toxinidir}
commands =
python -c 'from shutil import rmtree; rmtree("build", True); rmtree("dist", True)'
[testenv:lint]
description = Lint files using isort, black, and flake8
skip_install = True
changedir = {toxinidir}
deps =
black
flake8
flake8-bugbear
flake8-docstrings
isort
pep8-naming
commands =
flake8 src/nile tests/
black --check --diff src/nile tests
[testenv:format]
description = Format Python files using isort and black
skip_install = true
changedir = {toxinidir}
deps =
black
isort
commands =
isort src/nile tests
black src/nile tests