-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
102 lines (89 loc) · 1.97 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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
[base]
name = connectome_tools
testdeps =
mock
pytest
parameterized
xmltodict
[tox]
envlist =
check-version
check-packaging
lint
py{38,39,310,311,312}
minversion = 3.18
# ignore basepython for envs that already specify a version
ignore_basepython_conflict = true
[testenv]
basepython=python3.11
deps = {[base]testdeps}
commands = pytest -v tests {posargs}
setenv =
PIP_INDEX_URL = https://bbpteam.epfl.ch/repository/devpi/simple
[testenv:check-version]
skip_install = true
deps = bbp-nse-ci
commands = do_release.py -p . check-version
[testenv:check-packaging]
skip_install = true
deps =
wheel
twine
build
commands_pre =
rm -Rf {envtmpdir}/dist {[base]name}.egg-info
commands =
python -m build --outdir {envtmpdir}/dist
twine check {envtmpdir}/dist/*
allowlist_externals = rm
[testenv:lint]
deps =
black
darglint
isort
pycodestyle
pydocstyle
pylint
commands =
isort --check-only --diff {[base]name} tests setup.py
black --check {[base]name} tests setup.py
pycodestyle {[base]name}
pydocstyle {[base]name}
pylint {[base]name}
darglint -v2 {[base]name}
[testenv:format]
deps =
black
isort
commands =
isort {[base]name} tests setup.py
black {[base]name} tests setup.py
[testenv:coverage]
deps =
{[base]testdeps}
coverage
commands =
coverage run --source={[base]name} -m pytest tests/
coverage report --show-missing
coverage xml
[testenv:docs]
changedir = doc
deps =
extras = docs
# set warnings as errors using the -W sphinx option
commands = make html SPHINXOPTS=-W
allowlist_externals = make
# E731: do not assign a lambda expression, use a def
# W503: line break after binary operator
# W504: line break before binary operator
[pycodestyle]
ignore = E731,W503,W504
max-line-length = 100
[pydocstyle]
# ignore the following
# - D413: no blank line after last section
add-ignore = D413
convention = google
[darglint]
strictness=short
docstring_style=google