-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
77 lines (66 loc) · 1.87 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
[tox]
envlist = pip-compile, docs, lint, mypy, security, py39, py310, py311, py312, py313
[testenv]
envdir = {toxworkdir}/shared-environment
deps=
-r requirements-test.txt
usedevelop=true
download=true
commands=
pytest -vv \
--cov-config .coveragerc --cov=cloudpub --cov-report term \
--cov-report xml --cov-report html {posargs}
[testenv:pip-compile]
basepython = python3.9
skip_install = true
deps = pip-tools
commands =
pip-compile -U --generate-hashes --reuse-hashes --output-file=requirements.txt
pip-compile -U --generate-hashes --reuse-hashes --output-file=requirements-test.txt setup.py requirements-test.in
[testenv:docs]
use_develop=true
deps = -r requirements-test.txt
commands=
sphinx-build -M html docs docs/_build
[testenv:lint]
skip_install = true
deps =
black >= 23.1.0
flake8
flake8-docstrings
isort
commands =
flake8 --max-line-length=100 --ignore=D100,D104,D105 --per-file-ignores=tests/*:D101,D102,D103 cloudpub tests
black -S -t py39 -l 100 --check --diff cloudpub tests
isort -l 100 --profile black --check --diff cloudpub tests
[testenv:mypy]
basepython = python3.9
deps = -r requirements-test.txt
commands = mypy --ignore-missing-imports --exclude '^venv.*' .
[testenv:security]
skip_install = true
deps =
bandit
safety
commands =
bandit -s B303 -r cloudpub
safety check -r requirements.txt
[testenv:autoformat]
skip_install = true
deps =
black >= 23.1.0
isort
commands =
black -S -t py39 -l 100 cloudpub tests
isort -l 100 --profile black cloudpub tests
[testenv:azure_schemas]
skip_install = true
deps = -r requirements.txt
commands = python schemas/download_azure_schemas.py {posargs}
[testenv:coverage]
basepython = python3.9
deps = -r requirements-test.txt
relative_files = True
usedevelop= True
commands=
pytest --cov-report=html --cov-report=xml --cov=cloudpub {posargs}