-
Notifications
You must be signed in to change notification settings - Fork 67
/
tox.ini
60 lines (53 loc) · 1.94 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
[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
passenv = {[testenv]passenv}
deps = {[testenv]deps}
coverage>=6.0
extras = toml
commands_pre = coverage --version
coverage erase
{[testenv]commands_pre}
commands = coverage run --source=setools,setoolsgui -m pytest tests
coverage report
[testenv:lint]
passenv = {[testenv]passenv}
deps = {[testenv]deps}
pylint>=2.8.0
commands_pre = pylint --version
{[testenv]commands_pre}
commands = pylint -E setools setoolsgui tests seinfo seinfoflow sedta sesearch sediff sechecker apol
[testenv:mypy]
deps = {[testenv]deps}
types-setuptools
mypy>=1.6.0
commands_pre = mypy --version
commands = mypy -p setools -p setoolsgui -p tests
mypy --scripts-are-modules seinfo seinfoflow sedta sesearch sediff sechecker apol
[testenv:install]
deps = {[testenv]deps}
allowlist_externals = find
commands = {envpython} -m pip install --use-pep517 --root {envtmpdir}/setools .
find {envtmpdir}/setools
[testenv]
passenv = USERSPACE_SRC
DISPLAY
XAUTHORITY
deps = networkx>=2.6
cython>=0.29.14
pytest>=6.0
PyQt6>=6.0
pygraphviz
pytest-qt
pytest-xvfb
commands_pre = {envpython} setup.py build_ext -i
commands = {envpython} -m pytest tests