-
Notifications
You must be signed in to change notification settings - Fork 26
/
Copy pathtox.ini
49 lines (41 loc) · 1.2 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
[tox]
envlist = test, format-and-lint, docs
isolated_build = True
[testenv:test]
description = Execute all sorts of tests
deps =
pytest
pytest-cases
matplotlib
commands =
; The doctests in the src are not run here because the doc-build executes them
pytest {posargs}
python -m doctest docs/source/getting_started/application_icml2022.md
python -m doctest docs/source/getting_started/usage_example.md
[testenv:format-and-lint]
description = Lint the code with black, isort, and pylint
deps =
black
isort
nbqa
pylint
commands =
black --check --diff . --quiet
isort --check --diff . --quiet
nbqa black --check --diff . --quiet
nbqa isort --check --diff . --quiet
pylint tueplots --jobs=0 --score no
pylint tests --jobs=0 --disable="missing-function-docstring" --score no
[testenv:docs]
description = Build the HTML docs
passenv = HOME
deps =
# The doc-dependencies are separate because
# we need to be able to tell readthedocs where
# to find them (there is no access to tox).
-r {toxinidir}/docs/requirements-sphinx-build.txt
changedir = docs
allowlist_externals = make
commands =
make clean
make html SPHINXOPTS="-W --keep-going"