Fix fuel master node migration test

- Move assigned_slaves attribute from class scope of BaseActions
class to instance scope of ActionTest class. This is to have this
attribute reset before each template based test of the same run
(otherwise it brings slave info from the 1st test to 2nd and so on).
- Add waiting for cluster nodes to be online after migration.

Change-Id: Iafa38f0f3cfdaa04551ffbcdf6bdfacbdd0abedb
Partial-Bug: #1559050
This commit is contained in:
Dmitriy Kruglov 2016-03-24 08:58:51 +00:00
parent a413764bd6
commit dd7f148f57
3 changed files with 6 additions and 5 deletions

View File

@ -194,7 +194,6 @@ class BaseActions(PrepareActions, HealthCheckActions, PluginsActions):
base_group = None
actions_order = None
cluster_id = None
assigned_slaves = set()
scale_step = 0
def _add_node(self, nodes_list):

View File

@ -22,3 +22,4 @@ class ActionTest(base_test_case.TestBasic, ActionsFactory):
def __init__(self, config_file=None):
super(ActionTest, self).__init__()
self.config_file = config_file
self.assigned_slaves = set()

View File

@ -40,9 +40,8 @@ class FuelMasterMigrate(ActionTest, BaseActions, FuelMasterActions):
3. Deploy environment
4. Run network checker
5. Migrate Fuel Master to the compute node
6. Check that containers are up and running on the Fuel Master
7. Run network checker
8. Run OSTF
6. Run network checker
7. Run OSTF
"""
actions_order = [
@ -57,7 +56,6 @@ class FuelMasterMigrate(ActionTest, BaseActions, FuelMasterActions):
'network_check',
'start_fuel_migration',
'check_migration_status',
'check_containers',
'network_check',
'health_check'
]
@ -129,3 +127,6 @@ class FuelMasterMigrate(ActionTest, BaseActions, FuelMasterActions):
wait(lambda: not remote.exists("/notready"),
timeout=900,
timeout_msg="File wasn't removed in 900 sec")
self.fuel_web.wait_nodes_get_online_state(
self.env.d_env.nodes().slaves[:2])