-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
59 lines (52 loc) · 1.31 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
[tox]
skipsdist = true
envlist = format, check-format, py{312}-{flake8,test}
[testenv:py{312}-test]
deps =
-rrequirements.txt
-rrequirements-test.txt
pytest
commands = pytest
[testenv:check-format]
skip_install = true
basepython = python3.12
deps =
isort
black
commands =
isort --check-only --diff src/ tests/
black --line-length 80 --check --diff src/ tests/
#Falke8 is a tool that enforces PEP8 style guide
[testenv:py{312}-flake8]
skip_install = true
deps =
flake8
flake8-isort>=3.8.3
commands =
flake8 src/ tests/
# Not needed as this is ran as part of the VS code setup already
[testenv:format]
skip_install = true
basepython = python3.12
deps =
isort
black
commands =
isort src/ tests/
black --line-length 80 src/ tests/
[pytest]
pythonpath = src
testpaths = tests
filterwarnings =
error
ignore::DeprecationWarning
[testenv:requirements]
#skip_install = true
basepython = python3.12
deps = pip-tools
setenv =
CUSTOM_COMPILE_COMMAND = tox -e requirements
commands =
pip-compile --upgrade --allow-unsafe --resolver=backtracking --strip-extras requirements.in
pip-compile --upgrade --allow-unsafe --resolver=backtracking --strip-extras requirements-test.in
pip-compile --upgrade --allow-unsafe --resolver=backtracking --strip-extras requirements-dev.in