-
Notifications
You must be signed in to change notification settings - Fork 3
/
tox.ini
115 lines (98 loc) · 2.41 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
[tox]
envlist = {py38,py39,py310}-{typecheck,test},lint,docs,safety,oids
isolated_build = True
[testenv]
passenv = TERM
deps =
typecheck: -rpackaging/requirements-typecheck.txt
test: -rpackaging/requirements-test.txt
commands_pre =
typecheck: python -m rpkimancer.asn1.mod
commands =
typecheck: mypy --package rpkimancer \
typecheck: --config-file {toxinidir}/tox.ini
test: py.test {posargs:-m 'not rpki_client'} \
test: -ra -vs --strict-markers \
test: --cov {envsitepackagesdir}/rpkimancer \
test: --cov-report term-missing \
test: --cov-report xml \
test: --cov-branch
[testenv:lint]
deps = -rpackaging/requirements-lint.txt
commands =
flake8 .
[testenv:docs]
deps = -rpackaging/requirements-docs.txt
commands =
sphinx-multiversion -E docs/ build/docs/html/
[testenv:safety]
deps = -rpackaging/requirements-safety.txt
commands =
safety check --full-report
safety check -r packaging/requirements-dev.txt --full-report
[testenv:oids]
deps = -rpackaging/requirements-oids.txt
commands =
python object-identifiers/validate.py
[gh-actions]
python =
3.8: py38
3.9: py39
3.10: py310
[gh-actions:env]
TOX_JOB =
lint: lint
typecheck: typecheck
test: test
docs: docs
safety: safety
oids: oids
[pytest]
markers =
rpki_client: mark tests requiring rpki-client to be installed
[mypy]
pretty = True
strict = True
show_error_codes = True
exclude = rpkimancer/asn1/mod/_mod\.py$
[mypy-rpkimancer.asn1.mod]
implicit_reexport = True
[mypy-rpkimancer.asn1.mod._mod]
follow_imports = silent
[mypy-argcomplete.*]
ignore_missing_imports = True
[mypy-pycrate_asn1c.*]
ignore_missing_imports = True
[mypy-pycrate_asn1rt.*]
ignore_missing_imports = True
[coverage:run]
source = rpkimancer
omit =
*/rpkimancer/asn1/mod/_mod.py
*/rpkimancer/asn1/mod/__main__.py
[coverage:report]
exclude_lines =
pragma: no cover
def __repr__
if __name__ == .__main__.:
if typing.TYPE_CHECKING:
raise NotImplementedError
raise io.UnsupportedOperation
[flake8]
max-line-length = 79
doctests = True
docstring-convention = pep257
radon-max-cc = 10
statistics = True
count = True
exclude =
.git,
__pycache__,
build,
dist,
.venv,
.tox,
rpkimancer/asn1/mod/_mod.py
per-file-ignores =
rpkimancer/**/__init__.py:F401
tests/*.py:S101,S404,S603