forked from pycontribs/selinux
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
96 lines (90 loc) · 2.24 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
[tox]
envlist = lint,dist,py27,py35,py36,py37,py38,distros
minversion = 3.4.0
ignore_basepython_conflict = True
skip_missing_interpreters = True
skipdist = True
[testenv]
usedevelop = True
setenv =
ANSIBLE_CALLBACK_WHITELIST={env:ANSIBLE_CALLBACK_WHITELIST:profile_tasks}
ANSIBLE_FORCE_COLOR={env:ANSIBLE_FORCE_COLOR:1}
ANSIBLE_INVENTORY={toxinidir}/tests/hosts.ini
ANSIBLE_NOCOWS=1
ANSIBLE_RETRY_FILES_ENABLED=0
ANSIBLE_STDOUT_CALLBACK={env:ANSIBLE_STDOUT_CALLBACK:debug}
ANSIBLE_VERBOSITY={env:ANSIBLE_VERBOSITY:0}
PIP_DISABLE_PIP_VERSION_CHECK=1
PY_COLORS={env:PY_COLORS:1}
# MOLECULE_DEBUG=1
# pip: Avoid 2020-01-01 warnings: https://github.com/pypa/pip/issues/6207
PYTHONWARNINGS=ignore:DEPRECATION::pip._internal.cli.base_command
PYTHONDONTWRITEBYTECODE=1
passenv =
ANSIBLE_*
CI
CURL_CA_BUNDLE
DOCKER_*
MOLECULE_*
PYTEST_OPTIONS
REQUESTS_CA_BUNDLE
SSH_AUTH_SOCK
SSL_CERT_FILE
TERM
TOXENV
TRAVIS
TRAVIS_*
TWINE_*
whitelist_externals =
bash
rm
# DO NOT EVER ENABLE THIS, AS WE MUST RUN ISOLATED, otherwise the real
# selinux package from the system would be importable and we would fail
# to test our shim module.
sitepackages = false
commands =
python -c "import selinux"
# check for conflicts after install
python -m pip check
[testenv:distros]
deps =
; {[testenv]deps}
paramiko>=2.5.0
molecule[docker]>=3.1
pytest
pytest-instafail
pytest-molecule
commands =
pytest --color=yes {tty:-s:-s}
[testenv:lint]
deps =
pip>=19.1.1
pre-commit>=1.18.3
setuptools>=39.0
commands =
python -m pre_commit run -a
[testenv:dist]
deps =
collective.checkdocs>=0.2
pep517 >= 0.5.0
pip>=19.1.1
setuptools>=39.0
twine>=1.13.0
wheel>=0.31.0
commands =
rm -rf {toxinidir}/dist
python setup.py check -m -s
# disabled due to errors with older setuptools:
# python setup.py sdist bdist_wheel
python -m pep517.build \
--source \
--binary \
--out-dir {toxinidir}/dist/ \
{toxinidir}
python -m twine check {toxinidir}/dist/*
[testenv:upload]
envdir = {toxworkdir}/dist
deps = {[testenv:dist]deps}
commands =
{[testenv:dist]commands}
twine upload dist/*