Skip to content

Commit db93017

Browse files
committed
tox: rework to have "common" sections + enable py37 envs.
1 parent 897389f commit db93017

File tree

1 file changed

+27
-13
lines changed

1 file changed

+27
-13
lines changed

tox.ini

Lines changed: 27 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
[tox]
22
envlist=
3-
py37-core
43
py{35,36}-{core,database,transactions,vm,native-blockchain}
54
py{36}-{benchmark,p2p,trinity}
65
py{36}-rpc-blockchain
76
py{36}-rpc-state-{frontier,homestead,eip150,eip158,byzantium,quadratic}
87
py{35,36}-native-state-{frontier,homestead,eip150,eip158,byzantium,constantinople,metropolis}
8+
py37-{core,trinity,trinity-integration}
99
lint-py{35,36}
1010

1111
[flake8]
@@ -61,9 +61,8 @@ commands=
6161
make validate-docs
6262

6363

64-
[testenv:py36-trinity-integration]
64+
[common-trinity-integration]
6565
deps = .[eth-extras, test]
66-
basepython=python3.6
6766
passenv =
6867
PYTEST_ADDOPTS
6968
TRAVIS_EVENT_TYPE
@@ -72,37 +71,52 @@ commands=
7271
# due to multiple Trinity instances competing for the same ports
7372
py.test -n 1 {posargs:tests/trinity/integration/}
7473

74+
[testenv:py36-trinity-integration]
75+
basepython=python3.6
76+
deps = {[common-trinity-integration]deps}
77+
passenv = {[common-trinity-integration]passenv}
78+
commands = {[common-trinity-integration]commands}
79+
80+
[testenv:py37-trinity-integration]
81+
basepython=python3.7
82+
deps = {[common-trinity-integration]deps}
83+
passenv = {[common-trinity-integration]passenv}
84+
commands = {[common-trinity-integration]commands}
85+
7586

7687
[testenv:py36-benchmark]
77-
deps = .[eth-extras, benchmark]
7888
basepython=python3.6
89+
deps = .[eth-extras, benchmark]
7990
commands=
8091
benchmark: {toxinidir}/scripts/benchmark/run.py
8192

8293

83-
[testenv:lint-py35]
94+
[common-lint]
8495
deps = .[lint]
85-
basepython=python3.5
8696
setenv=MYPYPATH={toxinidir}:{toxinidir}/stubs
8797
commands=
8898
flake8 {toxinidir}/eth
99+
100+
[testenv:lint-py35]
101+
basepython=python3.5
102+
deps = {[common-lint]deps}
103+
setenv = {[common-lint]setenv}
104+
commands=
105+
{[common-lint]commands}
89106
flake8 {toxinidir}/tests --exclude="trinity,p2p"
90107
# TODO: Drop --ignore-missing-imports once we have type annotations for eth_utils, coincurve and cytoolz
91108
mypy --follow-imports=silent --ignore-missing-imports --no-strict-optional --check-untyped-defs --disallow-incomplete-defs -p eth
92109

93-
94110
[testenv:lint-py36]
95-
deps = .[lint]
96111
basepython=python3.6
97-
setenv=MYPYPATH={toxinidir}:{toxinidir}/stubs
112+
deps = {[common-lint]deps}
113+
setenv = {[common-lint]setenv}
98114
commands=
99-
flake8 {toxinidir}/eth
115+
{[common-lint]commands}
116+
flake8 {toxinidir}/tests
100117
flake8 {toxinidir}/p2p
101118
flake8 {toxinidir}/trinity
102-
flake8 {toxinidir}/tests
103119
flake8 {toxinidir}/scripts
104120
# TODO: Drop --ignore-missing-imports once we have type annotations for eth_utils, coincurve and cytoolz
105121
mypy --follow-imports=silent --ignore-missing-imports --no-strict-optional --check-untyped-defs --disallow-incomplete-defs --disallow-untyped-defs --disallow-any-generics scripts/benchmark
106122
mypy --follow-imports=silent --ignore-missing-imports --no-strict-optional --check-untyped-defs --disallow-incomplete-defs --disallow-untyped-defs --disallow-any-generics -p p2p -p trinity
107-
108-

0 commit comments

Comments
 (0)