forked from taxprofiler/taxpasta
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
99 lines (88 loc) · 2.14 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
[tox]
envlist = bandit, flake8, safety, mypy, docs, install, py3{8,9,10,11}
[gh-actions]
python =
3.8: install, safety, py38
3.9: install, safety, py39
3.10: install, safety, py310
3.11: bandit, flake8, install, safety, mpypy, docs, py311
[testenv]
# Define base for all test environments.
parallel_show_output = true
# Run bandit separately instead of flake8-bandit plugin due to:
# https://github.com/tylerwince/flake8-bandit/issues/33
[testenv:bandit]
skip_install = True
deps=
bandit[toml]
commands=
bandit --configfile pyproject.toml --recursive {toxinidir}/src/taxpasta {toxinidir}/tests
[testenv:flake8]
skip_install = True
# We provide constraints here to speed up the new pip backtracking dependency
# resolution. It takes forever otherwise.
deps=
darglint ~=1.8
flake8 ~=5.0
flake8-black ~=0.3
flake8-bugbear ~=22.10
flake8-builtins ~=2.0
flake8-comprehensions ~= 3.10
flake8-docstrings ~=1.6
flake8-eradicate ~=1.4
flake8-isort ~=5.0
flake8-pytest-style ~=1.6
commands=
flake8 {toxinidir}/src/taxpasta {toxinidir}/tests
[testenv:safety]
deps=
safety
commands=
safety check --full-report
[testenv:mypy]
skip_install = True
deps=
mypy
commands=
mypy {toxinidir}/src/taxpasta
[testenv:docs]
skip_install = True
deps=
-r{toxinidir}/docs/requirements.txt
commands=
mkdocs build --strict
[testenv:install]
skip_install = True
deps=
hatch
twine
commands=
pip check {toxinidir}
hatch build
twine check {toxinidir}/dist/*
[testenv:py3{8,9,10,11}]
deps =
pytest
pytest-cov
pytest-raises
pytest-xdist
extras =
all
commands =
pytest --cov=taxpasta --cov-report=term {posargs}
################################################################################
# Testing tools configuration #
################################################################################
[flake8]
max-line-length = 88
exclude =
__init__.py
_version.py
# The following conflict with `black` which is the more pedantic.
ignore =
E203
W503
D202
# darglint
strictness = long
docstring_style = google