-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
82 lines (71 loc) · 1.51 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
[tox]
requires =
tox>=4.2
env_list =
lint
py312
py311
py310
py39
py38
py37
pkg_meta
skip_missing_interpreters = true
[testenv]
description = run the tests with pytest under {envname}
deps =
pytest
pytest-cov
commands =
pytest
[testenv:lint]
description = format the code base to adhere to our styles, and complain about what we cannot do automatically
base_python = py312
deps =
pre-commit>=3.2
commands =
pre-commit run --all-files --show-diff-on-failure {posargs}
python -c 'print(r"hint: run {envbindir}{/}pre-commit install to add checks as pre-commit hook")'
[testenv:pkg_meta]
description = check that generated packages are valid
base_python = py312
skip_install = true
deps =
build[virtualenv]>=0.10
check-wheel-contents>=0.4
twine>=4.0.2
commands =
python3 -m build --outdir {envtmpdir} --sdist --wheel .
twine check --strict {envtmpdir}{/}*
check-wheel-contents {envtmpdir}
[testenv:sample]
base_python = py312
deps =
commands =
commit-message-validator sample {posargs}
[flake8]
exclude = .tox
max_line_length = 120
[pytest]
addopts =
--doctest-modules
--verbosity=2
--cov=commit_message_validator
--cov-report=term
--cov-report=html
--cov-report=xml
--junitxml=dist/junit.xml
[coverage:run]
branch = True
omit =
**/__main__.py
[coverage:report]
show_missing = True
skip_empty = True
[coverage:html]
directory = dist/htmlcov
[coverage:xml]
output = dist/coverage.xml
[check-wheel-contents]
ignore =
W002,