Fix ovn_migration and ovn_migration_sanity testenvs
For some reason, an env variable's (RUN_TESTS_EXTRA_ARGS) default value was not properly overwritten on these testenvs. Its default value has been removed, since it's not relevant for other testenvs. Besides this, the marker skip_during_ovn_migration has been added to the test test_equal_containers_state because it should not be executed after ovn-migration (list of containers changes, so comparison between previous and new containers is not relevant). Also, the background ping test will be skipped for ovn_migration and ovn_migration_sanity testenvs because the may be traffic loss during the migration process. Change-Id: I71de87e5216ac2d6c7e198ea6236fe189b79408d
This commit is contained in:
parent
1e284970c1
commit
2945010168
@ -5,6 +5,7 @@ markers =
|
|||||||
ovn_migration: test cases for testing OVN migration
|
ovn_migration: test cases for testing OVN migration
|
||||||
minimal: most relevant and lightweight test cases
|
minimal: most relevant and lightweight test cases
|
||||||
skip_during_ovn_migration: test cases which shouldn't be run in the OVS to OVN migration jobs
|
skip_during_ovn_migration: test cases which shouldn't be run in the OVS to OVN migration jobs
|
||||||
|
background: test traffic loss using a background process sending pings to a VM instance
|
||||||
|
|
||||||
|
|
||||||
# rp_uuid = 887ab577-b89e-4b12-9d8f-03f7a0a5b14a
|
# rp_uuid = 887ab577-b89e-4b12-9d8f-03f7a0a5b14a
|
||||||
|
@ -22,6 +22,7 @@ import time
|
|||||||
import testtools
|
import testtools
|
||||||
from oslo_log import log
|
from oslo_log import log
|
||||||
import pandas
|
import pandas
|
||||||
|
import pytest
|
||||||
|
|
||||||
import tobiko
|
import tobiko
|
||||||
from tobiko.openstack import neutron
|
from tobiko.openstack import neutron
|
||||||
@ -207,6 +208,7 @@ class TripleoContainersHealthTest(BaseContainersHealtTest):
|
|||||||
def test_ovn_containers_running(self):
|
def test_ovn_containers_running(self):
|
||||||
tripleo_containers.assert_ovn_containers_running()
|
tripleo_containers.assert_ovn_containers_running()
|
||||||
|
|
||||||
|
@pytest.mark.skip_during_ovn_migration
|
||||||
def test_equal_containers_state(self, expected_containers_list=None,
|
def test_equal_containers_state(self, expected_containers_list=None,
|
||||||
timeout=120, interval=5,
|
timeout=120, interval=5,
|
||||||
recreate_expected=False):
|
recreate_expected=False):
|
||||||
|
12
tox.ini
12
tox.ini
@ -26,9 +26,9 @@ setenv =
|
|||||||
OS_STDOUT_CAPTURE = {env:OS_STDOUT_CAPTURE:true}
|
OS_STDOUT_CAPTURE = {env:OS_STDOUT_CAPTURE:true}
|
||||||
OS_STDERR_CAPTURE = {env:OS_STDERR_CAPTURE:true}
|
OS_STDERR_CAPTURE = {env:OS_STDERR_CAPTURE:true}
|
||||||
OS_TEST_PATH = {toxinidir}/tobiko/tests/unit
|
OS_TEST_PATH = {toxinidir}/tobiko/tests/unit
|
||||||
|
TOBIKO_TEST_PATH = {env:OS_TEST_PATH}
|
||||||
PYTEST_TIMEOUT = {env:PYTEST_TIMEOUT:300}
|
PYTEST_TIMEOUT = {env:PYTEST_TIMEOUT:300}
|
||||||
PYTHONWARNINGS = ignore::Warning,{env:PYTHONWARNINGS:}
|
PYTHONWARNINGS = ignore::Warning,{env:PYTHONWARNINGS:}
|
||||||
RUN_TESTS_EXTRA_ARGS = {env:OS_TEST_PATH}
|
|
||||||
TOBIKO_PREVENT_CREATE = {env:TOBIKO_PREVENT_CREATE:false}
|
TOBIKO_PREVENT_CREATE = {env:TOBIKO_PREVENT_CREATE:false}
|
||||||
TOX_COVER = {env:TOX_COVER:false}
|
TOX_COVER = {env:TOX_COVER:false}
|
||||||
TOX_COVER_DIR = {env:TOX_COVER_DIR:{toxinidir}/cover}
|
TOX_COVER_DIR = {env:TOX_COVER_DIR:{toxinidir}/cover}
|
||||||
@ -39,7 +39,7 @@ setenv =
|
|||||||
TOX_EXTRA_REQUIREMENTS = {env:TOX_EXTRA_REQUIREMENTS:-r{toxinidir}/extra-requirements.txt}
|
TOX_EXTRA_REQUIREMENTS = {env:TOX_EXTRA_REQUIREMENTS:-r{toxinidir}/extra-requirements.txt}
|
||||||
VIRTUAL_ENV = {envdir}
|
VIRTUAL_ENV = {envdir}
|
||||||
commands =
|
commands =
|
||||||
{envpython} {toxinidir}/tools/run_tests.py {posargs:{env:RUN_TESTS_EXTRA_ARGS}}
|
{envpython} {toxinidir}/tools/run_tests.py {posargs:{env:TOBIKO_TEST_PATH}}
|
||||||
|
|
||||||
|
|
||||||
[testenv:py3]
|
[testenv:py3]
|
||||||
@ -230,7 +230,9 @@ passenv = {[integration]passenv}
|
|||||||
setenv =
|
setenv =
|
||||||
{[testenv:scenario]setenv}
|
{[testenv:scenario]setenv}
|
||||||
OS_TEST_PATH = {toxinidir}/tobiko/tests/scenario
|
OS_TEST_PATH = {toxinidir}/tobiko/tests/scenario
|
||||||
RUN_TESTS_EXTRA_ARGS = -m "not skip_during_ovn_migration and not flaky" {env:OS_TEST_PATH}
|
RUN_TESTS_EXTRA_ARGS = -m "not skip_during_ovn_migration and not background and not flaky"
|
||||||
|
commands =
|
||||||
|
{envpython} {toxinidir}/tools/run_tests.py {env:RUN_TESTS_EXTRA_ARGS} {posargs:{env:TOBIKO_TEST_PATH}}
|
||||||
|
|
||||||
[testenv:nova]
|
[testenv:nova]
|
||||||
|
|
||||||
@ -269,7 +271,9 @@ envdir = {[integration]envdir}
|
|||||||
passenv = {[integration]passenv}
|
passenv = {[integration]passenv}
|
||||||
setenv =
|
setenv =
|
||||||
{[testenv:sanity]setenv}
|
{[testenv:sanity]setenv}
|
||||||
RUN_TESTS_EXTRA_ARGS = -m "ovn_migration and not skip_during_ovn_migration and not flaky" {env:OS_TEST_PATH}
|
RUN_TESTS_EXTRA_ARGS = -m "ovn_migration and not skip_during_ovn_migration and not background and not flaky"
|
||||||
|
commands =
|
||||||
|
{envpython} {toxinidir}/tools/run_tests.py {env:RUN_TESTS_EXTRA_ARGS} {posargs:{env:TOBIKO_TEST_PATH}}
|
||||||
|
|
||||||
|
|
||||||
[testenv:shiftstack_sanity]
|
[testenv:shiftstack_sanity]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user