summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinda Wang <wangwulin@huawei.com>2017-10-17 09:25:06 +0000
committerJose Lausuch <jalausuch@suse.com>2017-10-18 07:25:21 +0000
commitdf48fcce2ea7fea367789d9d7fd28996691accc4 (patch)
tree90d4ab62c05cd04d7375594fa26337e6cbfb5c89
parentf73a27258427b33a261c3e103ec1da25ef5c026b (diff)
Update blacklist about migration tests for rally
The test NovaServers.boot_and_migrate_server needs at least 2 compute nodes: https://github.com/openstack/rally/blob/stable/0.9/rally/plugins/openstack/scenarios/nova/servers.py#L763-L765 Change-Id: I4ddf99188094ced57225d886037b00e91f3b68e6 Signed-off-by: Linda Wang <wangwulin@huawei.com> (cherry picked from commit 613c672ac166ca92ce1284131ec06446e07e0023)
-rw-r--r--functest/opnfv_tests/openstack/rally/blacklist.txt3
-rw-r--r--functest/opnfv_tests/openstack/rally/rally.py8
-rw-r--r--functest/tests/unit/openstack/rally/test_rally.py4
3 files changed, 8 insertions, 7 deletions
diff --git a/functest/opnfv_tests/openstack/rally/blacklist.txt b/functest/opnfv_tests/openstack/rally/blacklist.txt
index cdb5be663..13d8fc5fc 100644
--- a/functest/opnfv_tests/openstack/rally/blacklist.txt
+++ b/functest/opnfv_tests/openstack/rally/blacklist.txt
@@ -53,8 +53,9 @@ scenario:
functionality:
-
functions:
- - no_live_migration
+ - no_migration
tests:
- NovaServers.boot_and_live_migrate_server
- NovaServers.boot_server_attach_created_volume_and_live_migrate
- NovaServers.boot_server_from_volume_and_live_migrate
+ - NovaServers.boot_and_migrate_server
diff --git a/functest/opnfv_tests/openstack/rally/rally.py b/functest/opnfv_tests/openstack/rally/rally.py
index c295b05aa..fd251899b 100644
--- a/functest/opnfv_tests/openstack/rally/rally.py
+++ b/functest/opnfv_tests/openstack/rally/rally.py
@@ -203,8 +203,8 @@ class RallyBase(testcase.TestCase):
return True
- def _live_migration_supported(self):
- """Determine if live migration is supported."""
+ def _migration_supported(self):
+ """Determine if migration is supported."""
if self.compute_cnt > 1:
return True
@@ -274,8 +274,8 @@ class RallyBase(testcase.TestCase):
with open(RallyBase.BLACKLIST_FILE, 'r') as black_list_file:
black_list_yaml = yaml.safe_load(black_list_file)
- if not self._live_migration_supported():
- func_list.append("no_live_migration")
+ if not self._migration_supported():
+ func_list.append("no_migration")
if 'functionality' in black_list_yaml.keys():
for item in black_list_yaml['functionality']:
diff --git a/functest/tests/unit/openstack/rally/test_rally.py b/functest/tests/unit/openstack/rally/test_rally.py
index 40aab9527..6a85536da 100644
--- a/functest/tests/unit/openstack/rally/test_rally.py
+++ b/functest/tests/unit/openstack/rally/test_rally.py
@@ -167,9 +167,9 @@ class OSRallyTesting(unittest.TestCase):
@mock.patch('__builtin__.open', mock.mock_open())
@mock.patch('functest.opnfv_tests.openstack.rally.rally.yaml.safe_load',
return_value={'functionality': [
- {'functions': ['no_live_migration'], 'tests': ['test']}]})
+ {'functions': ['no_migration'], 'tests': ['test']}]})
@mock.patch('functest.opnfv_tests.openstack.rally.rally.RallyBase.'
- '_live_migration_supported', return_value=False)
+ '_migration_supported', return_value=False)
def test_excl_func_default(self, mock_func, mock_yaml_load):
CONST.__setattr__('INSTALLER_TYPE', 'test_installer')
CONST.__setattr__('DEPLOY_SCENARIO', 'test_scenario')