forked from SELinuxProject/setools
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
63 lines (56 loc) · 2.02 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
[tox]
minversion = 2.4
envlist = python3, pep8, lint, mypy
[pycodestyle]
max-line-length = 100
[testenv:pep8]
deps = {[testenv]deps}
pycodestyle
commands_pre = pycodestyle --version
commands = pycodestyle setools/ setoolsgui/ tests/ seinfo seinfoflow sedta sesearch sediff sechecker apol --statistics
[testenv:coverage]
setenv = SETOOLS_COVERAGE = 1
deps = {[testenv]deps}
coverage>=5.0
extras = toml
commands_pre = coverage --version
coverage erase
{envpython} setup.py build_ext -i
commands = coverage run -m pytest tests
coverage report
[testenv:lint]
deps = {[testenv]deps}
pylint>=2.8.0
commands_pre = pylint --version
{envpython} setup.py build_ext -i
commands = pylint -E setools tests seinfo seinfoflow sedta sesearch sediff sechecker
# pylint can't see all members introduced by PyQt uic
pylint -E --disable=no-member,import-error,no-name-in-module setoolsgui apol
[testenv:mypy]
deps = {[testenv]deps}
types-setuptools
mypy
commands_pre = mypy --version
commands = mypy -p setools
mypy -p setoolsgui
mypy seinfo
mypy seinfoflow
mypy sedta
mypy sesearch
mypy sediff
mypy sechecker
mypy apol
[testenv:install]
deps = {[testenv]deps}
commands = {envpython} -m pip install --use-pep517 .
[testenv]
passenv = USERSPACE_SRC
deps = networkx>=2.0
cython>=0.29.14
pytest>=6.0
python3.6: dataclasses
python3.9: networkx>=2.6
python3.10: networkx>=2.6
python3.11: networkx>=2.6
commands_pre = {envpython} setup.py build_ext -i
commands = pytest tests