-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathtox.ini
55 lines (45 loc) · 1.06 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
[tox]
# https://github.com/tox-dev/tox/issues/3238
requires = tox==4.14.0
# these are the default environments, i.e. the list of tests running when you
# execute `tox` in the command-line without anything else
envlist =
lint
tests
[testenv]
passenv = *
lint-folders = "{toxinidir}/rholearn"
packaging_deps =
setuptools
wheel
cmake
[testenv:lint]
description =
lint the Python code with flake8 (code linter), black (code formatter), and isort
(sorting of imports)
package = skip
deps =
black
blackdoc
flake8
flake8-bugbear
isort
commands =
flake8 {[testenv]lint-folders}
black --check --diff {[testenv]lint-folders}
blackdoc --check --diff {[testenv]lint-folders}
isort --check-only --diff {[testenv]lint-folders}
[testenv:format]
description = Abuse tox to do actual formatting on all files.
package = skip
deps =
black
blackdoc
isort
commands =
black {[testenv]lint-folders}
blackdoc {[testenv]lint-folders}
isort {[testenv]lint-folders}
[flake8]
max_line_length = 88
extend-ignore = E203