-
Notifications
You must be signed in to change notification settings - Fork 2
/
tox.ini
53 lines (49 loc) · 1006 Bytes
/
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
[tox]
isolated_build = True
min_version = 4.0.0
envlist =
py310
py311
py312
py313
lint
type
[testenv]
description = Run all tests/checks
package = wheel
wheel_build_env = .pkg # Only works with universal wheels
deps =
-r requirements.txt
setenv =
COVERAGE_FILE = {toxworkdir}{/}.coverage.{envname}
PYTHONWARNINGS = ignore
commands =
coverage run \
--source={envsitepackagesdir}{/}bulletproof_python,{toxinidir}{/}tests \
-m pytest {posargs}
coverage report
[testenv:lint]
description = Run linters
skip_install = True
deps =
black
ruff
commands =
black --check src tests
ruff check src tests
[testenv:type]
description = Run type checks
skip_install = True
commands =
mypy --config-file=pyproject.toml src tests
[testenv:fix]
description = Run checks that may modify files
skip_install = True
deps =
black
ruff
pre-commit
commands =
black src tests
ruff --fix src tests
pre-commit run --all-files