zaqar-specs/tox.ini
Ghanshyam Mann 7aa078296c Fix doc job, pep8 error and remove py27
This commit does multiple fix
1. Doc building still use deprcated oslosphinx and incompatible
version of yasfb which lead to error-

sphinx.errors.ExtensionError: Could not import extension yasfb (exception: cannot import name 'logging')

Replace oslosphinx with openstackdocstheme to fix the error.

2. Switch py27 job with py37
3. fix the pep8 error

Change-Id: I33ad4d0a2924082b7c56ac7c7973ad02ac6e9df5
2019-12-17 18:47:52 +00:00

47 lines
968 B
INI

[tox]
minversion = 1.6
envlist = docs,pep8
skipsdist = True
[testenv]
basepython = python3
usedevelop = True
install_command = pip install -U {opts} {packages}
setenv =
VIRTUAL_ENV={envdir}
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
commands = stestr run --slowest {posargs}
[testenv:venv]
commands = {posargs}
[testenv:docs]
commands = python setup.py build_sphinx
[testenv:spelling]
deps =
-r{toxinidir}/requirements.txt
sphinxcontrib-spelling
PyEnchant
commands = sphinx-build -b spelling doc/source doc/build/spelling
[testenv:cover]
setenv =
PYTHON=coverage run --source specs --parallel-mode
commands =
stestr run {posargs}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
[testenv:pep8]
commands = flake8
[flake8]
# E123, E125 skipped as they are invalid PEP-8.
show-source = True
ignore = E123,E125
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build