-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
105 lines (93 loc) · 2.05 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
103
104
105
[tox]
minversion = 4.11
isolated_build = True
skip_missing_interpreters = true
envlist =
py38,py39,py310,py311
pre-commit
coverage
bandit
flake8
mypy
docs
[testenv]
description = run the test suite with (basepython)
skipsdist = True
package = wheel
wheel_build_env = .pkg
deps =
pytest~=7.4
commands =
pytest {posargs}
[testenv:pre-commit]
description = run the pre-commit checks to check toml, json, and yaml files
deps =
pre-commit~=2.15
pre-commit-hooks~=4.0
commands =
pre-commit run check-toml
pre-commit run check-yaml
pre-commit run check-json
[testenv:coverage]
description = run coverage
deps =
pytest~=7.4
pytest-cov~=4.1
commands =
pytest --cov-report term-missing --cov=sgdrf --cov-report=xml tests/
[testenv:bandit]
description = run bandit security checks
deps =
bandit~=1.7
commands =
bandit -r sgdrf
bandit -r tests --skip B101
[testenv:flake8]
description = lint with flake8
deps =
flake8~=6.1
flake8-bugbear>=21
flake8-docstrings~=1.5
commands =
flake8 sgdrf
flake8 docs
flake8 --ignore=D100,D101,D102,D103,D104,S101,W503,E203,E225,E301,E302,E501,D107,D200,D205,D400,D403,D409,D410,D411,D212,W391,W293 tests
[testenv:mypy]
description = check types with mypy
deps =
mypy~=1.5
commands =
mypy sgdrf
; mypy docs
; mypy tests
[testenv:docs]
description = build the documentation
deps =
sphinx>=7,<7.2.0
sphinx-autoapi~=3.0
sphinx-copybutton~=0.5
sphinx-rtd-theme~=1.0
tomlkit~=0.12
commands =
sphinx-build -b html docs docs/html
[coverage:run]
source = 'sgdrf'
[coverage:html]
directory = .coverage_report
[flake8]
max-line-length = 100
ignore = W503,E203,E225,E301,E302,E501,D107,D200,D205,D400,D403,D409,D410,D411,D212,W391,W293
doctests = true
exclude = .git
__pycache__/
build/
dist/
import-order-style = google
docstring-convention = google
[gh]
python =
3.12 = py312
3.11 = py311, pre-commit, coverage, bandit, flake8, mypy, docs
3.10 = py310
3.9 = py39a
3.8 = py38