Jim Rollenhagen | 4f8f229 | 2016-11-18 06:22:18 -0500 | [diff] [blame] | 1 | [tox] |
| 2 | minversion = 2.0 |
qingszhao | aee506f | 2018-06-12 10:36:26 +0800 | [diff] [blame] | 3 | envlist = py3,py27,pep8 |
Jim Rollenhagen | 4f8f229 | 2016-11-18 06:22:18 -0500 | [diff] [blame] | 4 | skipsdist = True |
| 5 | |
| 6 | [testenv] |
| 7 | usedevelop = True |
chenke | 2494c8a | 2019-06-17 21:49:34 +0800 | [diff] [blame^] | 8 | install_command = pip install {opts} {packages} |
Jim Rollenhagen | 4f8f229 | 2016-11-18 06:22:18 -0500 | [diff] [blame] | 9 | setenv = |
| 10 | VIRTUAL_ENV={envdir} |
| 11 | PYTHONWARNINGS=default::DeprecationWarning |
chenke | 2494c8a | 2019-06-17 21:49:34 +0800 | [diff] [blame^] | 12 | deps = -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} |
| 13 | -r{toxinidir}/test-requirements.txt |
Jim Rollenhagen | 4f8f229 | 2016-11-18 06:22:18 -0500 | [diff] [blame] | 14 | commands = python setup.py test --slowest --testr-args='{posargs}' |
| 15 | |
| 16 | [testenv:pep8] |
qingszhao | aee506f | 2018-06-12 10:36:26 +0800 | [diff] [blame] | 17 | basepython = python3 |
Jim Rollenhagen | 4f8f229 | 2016-11-18 06:22:18 -0500 | [diff] [blame] | 18 | commands = flake8 {posargs} |
| 19 | |
| 20 | [testenv:venv] |
qingszhao | aee506f | 2018-06-12 10:36:26 +0800 | [diff] [blame] | 21 | basepython = python3 |
Jim Rollenhagen | 4f8f229 | 2016-11-18 06:22:18 -0500 | [diff] [blame] | 22 | commands = {posargs} |
| 23 | |
| 24 | [testenv:cover] |
qingszhao | aee506f | 2018-06-12 10:36:26 +0800 | [diff] [blame] | 25 | basepython = python3 |
Jim Rollenhagen | 4f8f229 | 2016-11-18 06:22:18 -0500 | [diff] [blame] | 26 | commands = python setup.py test --coverage --testr-args='{posargs}' |
| 27 | |
| 28 | [testenv:docs] |
qingszhao | aee506f | 2018-06-12 10:36:26 +0800 | [diff] [blame] | 29 | basepython = python3 |
Jim Rollenhagen | 4f8f229 | 2016-11-18 06:22:18 -0500 | [diff] [blame] | 30 | commands = python setup.py build_sphinx |
| 31 | |
| 32 | [testenv:debug] |
qingszhao | aee506f | 2018-06-12 10:36:26 +0800 | [diff] [blame] | 33 | basepython = python3 |
Jim Rollenhagen | 4f8f229 | 2016-11-18 06:22:18 -0500 | [diff] [blame] | 34 | commands = oslo_debug_helper {posargs} |
| 35 | |
| 36 | [flake8] |
John L. Villalovos | d22378d | 2017-08-01 14:47:54 -0700 | [diff] [blame] | 37 | ignore = E129 |
Jim Rollenhagen | 4f8f229 | 2016-11-18 06:22:18 -0500 | [diff] [blame] | 38 | |
| 39 | show-source = True |
| 40 | builtins = _ |
| 41 | exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build |