Update tox.ini files based on release-tools gold copy
This charm cannot currently use the gold tox.ini files because the pep8 section requires python 3. Will need to maintain this separately/manually until another approach is determined to work. Change-Id: I424d19d38668979ed1f572be2d4f6113d51150ef
This commit is contained in:
parent
d1f71c348c
commit
f553903d96
11
src/tox.ini
11
src/tox.ini
|
@ -1,13 +1,16 @@
|
|||
# Source charm: ./src/tox.ini
|
||||
# This file is managed centrally by release-tools and should not be modified
|
||||
# within individual charm repos.
|
||||
[tox]
|
||||
envlist = pep8
|
||||
skipsdist = True
|
||||
|
||||
[testenv]
|
||||
envdir = .tox/py27
|
||||
setenv = VIRTUAL_ENV={envdir}
|
||||
PYTHONHASHSEED=0
|
||||
AMULET_SETUP_TIMEOUT=2700
|
||||
passenv = HOME TERM AMULET_HTTP_PROXY AMULET_OS_VIP
|
||||
whitelist_externals = juju
|
||||
passenv = HOME TERM AMULET_*
|
||||
deps = -r{toxinidir}/test-requirements.txt
|
||||
install_command =
|
||||
pip install --allow-unverified python-apt {opts} {packages}
|
||||
|
@ -23,28 +26,24 @@ commands =
|
|||
bundletester -vl DEBUG -r json -o func-results.json --test-pattern "gate-*" -n --no-destroy
|
||||
|
||||
[testenv:func27]
|
||||
# Charm Functional Test
|
||||
# Run all gate tests which are +x (expected to always pass)
|
||||
basepython = python2.7
|
||||
commands =
|
||||
bundletester -vl DEBUG -r json -o func-results.json --test-pattern "gate-*" --no-destroy
|
||||
|
||||
[testenv:func27-smoke]
|
||||
# Charm Functional Test
|
||||
# Run a specific test as an Amulet smoke test (expected to always pass)
|
||||
basepython = python2.7
|
||||
commands =
|
||||
bundletester -vl DEBUG -r json -o func-results.json gate-basic-xenial-mitaka --no-destroy
|
||||
|
||||
[testenv:func27-dfs]
|
||||
# Charm Functional Test
|
||||
# Run all deploy-from-source tests which are +x (may not always pass!)
|
||||
basepython = python2.7
|
||||
commands =
|
||||
bundletester -vl DEBUG -r json -o func-results.json --test-pattern "dfs-*" --no-destroy
|
||||
|
||||
[testenv:func27-dev]
|
||||
# Charm Functional Test
|
||||
# Run all development test targets which are +x (may not always pass!)
|
||||
basepython = python2.7
|
||||
commands =
|
||||
|
|
32
tox.ini
32
tox.ini
|
@ -4,34 +4,22 @@ envlist = pep8,py34,py35
|
|||
skip_missing_interpreters = True
|
||||
|
||||
[testenv]
|
||||
basepython = python2.7
|
||||
setenv = VIRTUAL_ENV={envdir}
|
||||
PYTHONHASHSEED=0
|
||||
TERM=linux
|
||||
INTERFACE_PATH={toxinidir}/interfaces
|
||||
LAYER_PATH={toxinidir}/layers
|
||||
INTERFACE_PATH={toxinidir}/interfaces
|
||||
JUJU_REPOSITORY={toxinidir}/build
|
||||
passenv = http_proxy https_proxy
|
||||
install_command =
|
||||
pip install {opts} {packages}
|
||||
deps =
|
||||
-r{toxinidir}/requirements.txt
|
||||
-r{toxinidir}/requirements.txt
|
||||
|
||||
[testenv:build]
|
||||
basepython = python2.7
|
||||
commands =
|
||||
charm-build --log-level DEBUG -o {toxinidir}/build src
|
||||
|
||||
[testenv:venv]
|
||||
commands = {posargs}
|
||||
|
||||
[testenv:pep8]
|
||||
basepython = python3.4
|
||||
commands = flake8 {posargs} src/reactive src/lib unit_tests
|
||||
|
||||
# Disable py27 tests as this is a reactive python 3 charm. Once project
|
||||
# config has been updated this tox target can be removed
|
||||
[testenv:py27]
|
||||
commands = /bin/true
|
||||
charm-build --log-level DEBUG -o {toxinidir}/build src {posargs}
|
||||
|
||||
[testenv:py34]
|
||||
basepython = python3.4
|
||||
|
@ -42,3 +30,15 @@ commands = ostestr {posargs}
|
|||
basepython = python3.5
|
||||
deps = -r{toxinidir}/test-requirements.txt
|
||||
commands = ostestr {posargs}
|
||||
|
||||
[testenv:pep8]
|
||||
basepython = python3.4
|
||||
deps = -r{toxinidir}/test-requirements.txt
|
||||
commands = flake8 {posargs} src unit_tests
|
||||
|
||||
[testenv:venv]
|
||||
commands = {posargs}
|
||||
|
||||
[flake8]
|
||||
# E402 ignore necessary for path append before sys module import in actions
|
||||
ignore = E402
|
||||
|
|
Loading…
Reference in New Issue