80 lines
2.2 KiB

minversion = 2.9.1
skipsdist = True
envlist = py3,pep8
basepython = python3
usedevelop = True
install_command = pip install -U {opts} {packages}
passenv = OS_* STORYBOARD_*
setenv =
deps = -r{toxinidir}/requirements.txt
commands = stestr run {posargs}
stestr slowest
whitelist_externals = bash
setenv =
commands = flake8
commands = {posargs}
deps = -r{toxinidir}/doc/requirements.txt
commands =
rm -rf doc/html doc/build
rm -rf doc/source/apidoc doc/source/api
sphinx-build -W -b html doc/source doc/build/html
whitelist_externals = rm
setenv =
PYTHON=coverage run --source storyboard --parallel-mode
commands =
stestr run {posargs}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
# E125 and E128 are ignored on purpose, they are invalid pep8
# W503 is ignored on purpose, it is no longer valid pep8
# The following rules should either be addressed or determined to be
# skippable long term.
# E265 is ignored to make switch to newer hacking easier
# H216 is ignored to allow use of the mock library instead of unittest.mock
# H405 is ignored to make switch to newer hacking easier
ignore = E125,E128,E265,H216,H405,W503
builtins = _
show-source = True
# Do not install any requirements. We want this to be fast and work even if
# system dependencies are missing, since it's used to tell you what system
# dependencies are missing! This also means that bindep must be installed
# separately, outside of the requirements files.
deps = bindep
commands = bindep test
# The Launchpad bug import tool uses launchpadlib, which is not a typical
# runtime dependency of anything else in StoryBoard
deps = launchpadlib
commands = storyboard-migrate {posargs}
import_exceptions = storyboard._i18n