-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathtox.ini
65 lines (57 loc) · 1.9 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
[tox]
minversion = 2.0
envlist = black,pep8,py{27,37},functional-py27,functional-py36
skipsdist = True
[testenv]
usedevelop = True
install_command = pip install {opts} {packages}
setenv =
VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning
OS_TEST_PATH=./osc_placement_tree/tests/unit
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
-r{toxinidir}/test-requirements.txt
-r{toxinidir}/requirements.txt
commands = stestr run {posargs}
[testenv:functional-py27]
basepython = python2.7
setenv =
VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning
OS_TEST_PATH=./osc_placement_tree/tests/functional
passenv = OS_*
# serial needed as the functional test uses stable uuids
commands = stestr run --serial --test-path ./osc_placement_tree/tests/functional/ {posargs}
[testenv:functional-py36]
# Can only bump to python3.7 when openstackclient fixes the ABC deprecation
# warning as that interfere with our tests as the warning is printed to the
# terminal
basepython = python3.6
setenv =
VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning
OS_TEST_PATH=./osc_placement_tree/tests/functional
passenv = OS_*
# serial needed as the functional test uses stable uuids
commands = stestr run --serial --test-path ./osc_placement_tree/tests/functional/ {posargs}
[testenv:pep8]
basepython = python3.7
# run black in check mode and fail if it would change something
commands =
black --line-length 79 --check --diff ./osc_placement_tree
flake8 {posargs}
[testenv:black]
basepython = python3.7
commands =
black --line-length 79 ./osc_placement_tree
[testenv:venv]
basepython = python3
commands = {posargs}
[testenv:debug]
basepython = python3
commands = oslo_debug_helper {posargs}
[flake8]
show-source = True
builtins = _
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build