David Lyle | 64302f1 | 2016-04-29 15:46:34 -0600 | [diff] [blame] | 1 | [tox] |
| 2 | minversion = 1.6 |
| 3 | envlist = py34,py27,pypy,pep8 |
| 4 | skipsdist = True |
| 5 | |
| 6 | [testenv] |
| 7 | usedevelop = True |
| 8 | install_command = pip install -U {opts} {packages} |
| 9 | setenv = |
| 10 | VIRTUAL_ENV={envdir} |
| 11 | deps = -r{toxinidir}/test-requirements.txt |
Ha Manh Dong | 2d24cb7 | 2018-07-19 09:48:23 +0700 | [diff] [blame] | 12 | commands = stestr run --slowest {posargs} |
David Lyle | 64302f1 | 2016-04-29 15:46:34 -0600 | [diff] [blame] | 13 | |
| 14 | [testenv:pep8] |
qingszhao | 828a12c | 2018-06-12 13:53:38 +0800 | [diff] [blame] | 15 | basepython = python3 |
David Lyle | 64302f1 | 2016-04-29 15:46:34 -0600 | [diff] [blame] | 16 | commands = flake8 |
| 17 | |
| 18 | [testenv:venv] |
qingszhao | 828a12c | 2018-06-12 13:53:38 +0800 | [diff] [blame] | 19 | basepython = python3 |
David Lyle | 64302f1 | 2016-04-29 15:46:34 -0600 | [diff] [blame] | 20 | commands = {posargs} |
| 21 | |
| 22 | [testenv:cover] |
Doug Hellmann | d739396 | 2018-09-26 18:52:38 -0400 | [diff] [blame] | 23 | basepython = python3 |
Ha Manh Dong | 2d24cb7 | 2018-07-19 09:48:23 +0700 | [diff] [blame] | 24 | setenv = |
| 25 | {[testenv]setenv} |
| 26 | PYTHON=coverage run --source tempest_horizon --parallel-mode |
| 27 | commands = |
| 28 | stestr run {posargs} |
| 29 | coverage combine |
| 30 | coverage html -d cover |
| 31 | coverage xml -o cover/coverage.xml |
David Lyle | 64302f1 | 2016-04-29 15:46:34 -0600 | [diff] [blame] | 32 | |
David Lyle | 64302f1 | 2016-04-29 15:46:34 -0600 | [diff] [blame] | 33 | [testenv:debug] |
qingszhao | 828a12c | 2018-06-12 13:53:38 +0800 | [diff] [blame] | 34 | basepython = python3 |
David Lyle | 64302f1 | 2016-04-29 15:46:34 -0600 | [diff] [blame] | 35 | commands = oslo_debug_helper {posargs} |
| 36 | |
| 37 | [flake8] |
David Lyle | 64302f1 | 2016-04-29 15:46:34 -0600 | [diff] [blame] | 38 | show-source = True |
Andreas Jaeger | ecc60ca | 2020-03-28 12:13:24 +0100 | [diff] [blame] | 39 | # W504 line break after binary operator |
| 40 | # (W503 and W504 are incompatible and we need to choose one of them. |
| 41 | # Existing codes follows W503, so we disable W504.) |
| 42 | ignore = W504 |
David Lyle | 64302f1 | 2016-04-29 15:46:34 -0600 | [diff] [blame] | 43 | builtins = _ |
| 44 | exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build |