Merge pull request #2 from openstack-charmers/update-tox

Update tox to be in line with the latest reference (Octavia)
This commit is contained in:
David Ames 2019-02-27 11:13:42 +01:00 committed by GitHub
commit 2b9940047e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 12 additions and 17 deletions

29
tox.ini
View File

@ -3,37 +3,26 @@
# within individual charm repos.
[tox]
skipsdist = True
envlist = pep8,py34,py35
skip_missing_interpreters = True
envlist = pep8,py3
[testenv]
setenv = VIRTUAL_ENV={envdir}
PYTHONHASHSEED=0
TERM=linux
LAYER_PATH={toxinidir}/layers
INTERFACE_PATH={toxinidir}/interfaces
JUJU_REPOSITORY={toxinidir}/build
passenv = http_proxy https_proxy
passenv = http_proxy https_proxy INTERFACE_PATH LAYER_PATH
install_command =
pip install {opts} {packages}
deps =
-r{toxinidir}/requirements.txt
[testenv:build]
basepython = python2.7
basepython = python3
commands =
charm-build --log-level DEBUG -o {toxinidir}/build src {posargs}
[testenv:py27]
basepython = python2.7
# Reactive source charms are Python3-only, but a py27 unit test target
# is required by OpenStack Governance. Remove this shim as soon as
# permitted. http://governance.openstack.org/reference/cti/python_cti.html
whitelist_externals = true
commands = true
[testenv:py34]
basepython = python3.4
[testenv:py3]
basepython = python3
deps = -r{toxinidir}/test-requirements.txt
commands = ostestr {posargs}
@ -42,12 +31,18 @@ basepython = python3.5
deps = -r{toxinidir}/test-requirements.txt
commands = ostestr {posargs}
[testenv:py36]
basepython = python3.6
deps = -r{toxinidir}/test-requirements.txt
commands = ostestr {posargs}
[testenv:pep8]
basepython = python3.5
basepython = python3
deps = -r{toxinidir}/test-requirements.txt
commands = flake8 {posargs} src unit_tests
[testenv:venv]
basepython = python3
commands = {posargs}
[flake8]