[tox] envlist = py27,py35,pep8,pylint,docs skipsdist = True [testenv] usedevelop = True deps = -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} -r{toxinidir}/requirements.txt -r{toxinidir}/test-requirements.txt install_command = pip install {opts} {packages} setenv = VIRTUAL_ENV={envdir} whitelist_externals = find coverage rm python_files = test_*.py norecursedirs = .tox .venv [testenv:venv] commands = {posargs} [testenv:py27] basepython = python2.7 setenv = OS_TEST_PATH = ./freezerclient/tests/unit commands = find . -type f -name "*.py[c|o]" -delete python setup.py testr --coverage --testr-args="{posargs}" coverage report -m rm -f .coverage rm -rf .testrepository [testenv:py35] basepython = python3.5 setenv = OS_TEST_PATH = ./freezerclient/tests/unit commands = find . -type f -name "*.py[c|o]" -delete python setup.py testr --coverage --testr-args="{posargs}" coverage report -m rm -f .coverage rm -rf .testrepository [testenv:docs] commands = python setup.py build_sphinx [testenv:pep8] commands = flake8 freezerclient [testenv:pylint] commands = pylint --rcfile .pylintrc freezerclient [flake8] # Ignored hackings: # H104 -> empty file, only comments # H202 -> assertRaises(Exception, ...) too broad # H404 -> Multi line docstrings should start without a leading new line. # H405 -> Multi line docstrings should start with a one line summary followed by an empty line. ignore = H104,H202,H404,H405 # H106: Don’t put vim configuration in source files # H203: Use assertIs(Not)None to check for None enable-extensions=H106,H203 show-source = True exclude = .venv,.tox,dist,doc,*egg,releasenotes [testenv:releasenotes] commands = sphinx-build -a -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html