-
Notifications
You must be signed in to change notification settings - Fork 3
/
tox.ini
118 lines (106 loc) · 2.46 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
106
107
108
109
110
111
112
113
114
115
116
117
118
[tox]
basepython = python3.12
envlist =
check,
py312 # EOL 2028-10-31
py311 # EOL 2027-10-24
py310 # EOL 2026-10-04
py39 # EOL 2025-10-05
# py38 # EOL 2024-10-14
# py37 # EOL 2023-06-27
# py36 # EOL 2021-12-21
# py35, # EOL 2020-09-13
coverage,
skip_missing_interpreters = true
# TOX Test Environment
[testenv]
# usedevelop = True
extras =
# test
passenv =
# LC_ALL
# LANG
setenv =
COVERAGE_FILE=.coverage.{envname}
# Note: also honors .coveragerc:
deps =
pytest
pytest-cov
pytest-html
setuptools # for Py312
requests
# For local test server:
cheroot
lxml
wsgidav
# We want to test the PluginManager
psutil
stressor-ps
commands =
# Run everything from /tests folder:
python -V
; pip list
pytest -ra -v -x --durations=10 --cov=stressor --html=build/pytest/report-{envname}.html --self-contained-html {posargs}
[testenv:coverage]
skip_install = true
deps =
coverage
setenv =
COVERAGE_FILE = .coverage
commands =
coverage erase
coverage combine
coverage html
coverage report --fail-under=75.0
[testenv:lint]
skip_install = true
deps =
ruff
commands =
ruff -V
ruff check stressor tests setup.py
[testenv:check]
description = Check Black formatting, isort compliance, and ruff
; skip_install = true
deps =
black[jupyter] ~=24.4
isort
{[testenv:lint]deps}
changedir = {toxinidir}
commands =
isort --check-only --profile black stressor tests setup.py
black --check --diff stressor tests setup.py
{[testenv:lint]commands}
[testenv:format]
description = Reformat python code using Black and isort
; skip_install = true
deps =
{[testenv:check]deps}
changedir = {toxinidir}
commands =
isort --profile black stressor tests setup.py {posargs}
black stressor tests setup.py
{[testenv:lint]commands}
[testenv:docs]
description = Build Sphinx documentation (output directory: docs/sphinx-build)
changedir = docs
deps =
furo
lxml
python-dateutil
sphinx
sphinx_rtd_theme
myst_parser[linkify]
sphinxcontrib.mermaid
commands =
# http://www.sphinx-doc.org/en/master/man/sphinx-build.html
sphinx-build -b html sphinx sphinx-build
[testenv:bdist_msi]
description = Build MSI installer in dist/ (Windows only)
# basepython = python3.7
changedir = .
deps =
cx_Freeze
commands =
# http://www.sphinx-doc.org/en/master/man/sphinx-build.html
python setup_bdist_msi.py bdist_msi