# Tox (http://tox.testrun.org/) is a tool for running tests # in multiple virtualenvs. This configuration file will run the # test suite on all supported python versions. To use it, "pip install tox" # and then run "tox" from this directory. [tox] minversion = 1.6 envlist = py{36,35,27},pep8,docs,releasenotes skipsdist = True [testenv] usedevelop = True setenv = VIRTUAL_ENV={envdir} CONSTRAINTS_OPT=-c {env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} install_command = pip install -U {opts} {packages} commands = stestr run --slowest '{posargs}' deps = {env:CONSTRAINTS_OPT} -r{toxinidir}/requirements.txt -r{toxinidir}/test-requirements.txt whitelist_externals = sh [testenv:pep8] basepython = python3 commands = flake8 collectd_openstack [testenv:venv] basepython = python3 commands = {posargs} [testenv:docs] basepython = python3 #fixeme(sean-k-mooney): add -W to treat warnings as errors once warnings are fixed commands = sphinx-build doc/source doc/build [testenv:releasenotes] basepython = python3 #fixeme(sean-k-mooney): add -W to treat warnings as errors once warnings are fixed #NOTE(sean-k-mooney): our releasenotes crash sphinx so we should really fix them ... commands = sphinx-build -a -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html [pep8] max-line-length = 80 [flake8] # E123, E125 skipped as they are invalid PEP-8. max-line-length = 80 show-source = True ignore = E123,E125,E241 builtins = _ exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build