From 344a800c3eaa4f8b4903b4b6a31c494b7430071e Mon Sep 17 00:00:00 2001 From: Victor Ryzhenkin Date: Tue, 6 Sep 2016 13:30:34 +0300 Subject: [PATCH] Adjust test groups in the tests and fix typo - Use murano_plugin_upgrade test group for upgrade tests - Use 5 slaves for ha bvt test case with murano on controllers Change-Id: If8aef10f6687e26eaa9f435d33aa29cdefbaca3b --- .../murano_plugin/test_murano_plugin_bvt.py | 8 +-- .../test_murano_plugin_update.py | 68 +++++++++++-------- 2 files changed, 43 insertions(+), 33 deletions(-) diff --git a/murano_plugin_tests/murano_plugin/test_murano_plugin_bvt.py b/murano_plugin_tests/murano_plugin/test_murano_plugin_bvt.py index f087809..992bfba 100644 --- a/murano_plugin_tests/murano_plugin/test_murano_plugin_bvt.py +++ b/murano_plugin_tests/murano_plugin/test_murano_plugin_bvt.py @@ -77,7 +77,7 @@ class TestMuranoPluginBvt(api.MuranoPluginApi): Snapshot deploy_murano_plugin_on_controller_ha """ - self.env.revert_snapshot("ready_with_3_slaves") + self.env.revert_snapshot("ready_with_5_slaves") self.prepare_plugin() @@ -164,7 +164,7 @@ class TestMuranoPluginBvt(api.MuranoPluginApi): @test(depends_on_groups=['prepare_slaves_9'], groups=["deploy_murano_plugin_full_ha", "deploy", - "murano", "bvt"]) + "murano", "bvt", "deploy_murano_bvt"]) @log_snapshot_after_test def deploy_murano_plugin_full_ha(self): """Deploy a cluster with the Murano plugin in full HA mode. @@ -199,7 +199,7 @@ class TestMuranoPluginBvt(api.MuranoPluginApi): @test(depends_on=[deploy_murano_plugin], groups=["uninstall_deployed_murano_plugin", "uninstall", - "murano_plugin", "smoke", 'murano']) + "murano_plugin", "smoke", 'murano', "deploy_murano_bvt"]) @log_snapshot_after_test def uninstall_deployed_murano_plugin(self): """Uninstall the Murano plugin with a deployed environment @@ -223,7 +223,7 @@ class TestMuranoPluginBvt(api.MuranoPluginApi): @test(depends_on_groups=["prepare_slaves_3"], groups=["uninstall_murano_plugin", "uninstall", "murano_plugin", - "smoke", 'murano']) + "smoke", 'murano', "deploy_murano_bvt"]) @log_snapshot_after_test def uninstall_murano_plugin(self): """Uninstall the Murano plugin diff --git a/murano_plugin_tests/murano_plugin/test_murano_plugin_update.py b/murano_plugin_tests/murano_plugin/test_murano_plugin_update.py index a83e912..2ef26a1 100644 --- a/murano_plugin_tests/murano_plugin/test_murano_plugin_update.py +++ b/murano_plugin_tests/murano_plugin/test_murano_plugin_update.py @@ -24,25 +24,19 @@ class TestMuranoPluginUpdate(api.MuranoPluginApi): """Class for testing upgrades for Murano plugin.""" @test(depends_on_groups=["prepare_slaves_3"], - groups=["deploy_murano_and_plugin", "upgrade", - "murano"]) + groups=["deploy_murano_out_of_the_box", "murano"]) @log_snapshot_after_test - def deploy_murano_plugin_in_environment_with_murano(self): - """Upgrade Murano via plugin and run OSTF tests. + def deploy_murano_out_of_the_box(self): + """Deploy Murano out of the box and run OSTF tests Scenario: 1. Deploy Fuel Cluster with one controller and Murano 2. Run OSTF - 3. Upload plugin to master node - 4. Install plugin - 5. Activate plugin - 6. Update cluster (Deploy changes) - 7. Run OSTF + 3. Make snapshot Duration 90m - Snapshot deploy_murano_plugin_in_environment_with_murano + Snapshot deploy_murano_out_of_the_box """ - self.env.revert_snapshot("ready_with_3_slaves") self.helpers.create_cluster(name=self.__class__.__name__, @@ -52,6 +46,29 @@ class TestMuranoPluginUpdate(api.MuranoPluginApi): self.helpers.run_ostf(['sanity', 'smoke', 'tests_platform']) + self.env.make_snapshot("deploy_murano_out_of_the_box", is_make=True) + + @test(depends_on=[deploy_murano_out_of_the_box], + groups=["deploy_murano_and_plugin", "murano_plugin_upgrade", + "murano", + "deploy_murano_plugin_in_environment_with_murano"]) + @log_snapshot_after_test + def deploy_murano_plugin_in_environment_with_murano(self): + """Upgrade Murano via plugin and run OSTF tests. + + Scenario: + 1. Revert shapshot with box murano installation + 2. Upload plugin to master node + 3. Install plugin + 4. Activate plugin + 5. Update cluster (Deploy changes) + 6. Run OSTF + + Duration 60m + Snapshot deploy_murano_plugin_in_environment_with_murano + """ + self.env.revert_snapshot("deploy_murano_out_of_the_box") + self.prepare_plugin() self.activate_plugin() @@ -64,35 +81,28 @@ class TestMuranoPluginUpdate(api.MuranoPluginApi): "deploy_murano_plugin_in_environment_with_murano", is_make=False) - @test(depends_on_groups=["prepare_slaves_3"], + @test(depends_on=[deploy_murano_out_of_the_box], groups=["deploy_murano_and_plugin_add_role", "deploy", - "murano"]) + "murano", "murano_plugin_upgrade", + "deploy_murano_plugin_in_environment_with_murano"]) @log_snapshot_after_test def deploy_murano_node_in_environment_with_murano(self): """Upgrade Murano via plugin (adding murano-node) and run OSTF tests. Scenario: - 1. Deploy Fuel Cluster with one controller and Murano - 2. Run OSTF - 3. Upload plugin to master node - 4. Install plugin - 5. Activate plugin and add new node + 1. Revert shapshot with box murano installation + 2. Upload plugin to master node + 3. Install plugin + 4. Activate plugin and add new node with murano-node role to the cluster - 6. Update cluster (Deploy changes) - 7. Run OSTF + 5. Update cluster (Deploy changes) + 6. Run OSTF - Duration 120m + Duration 75m Snapshot deploy_murano_node_in_environment_with_murano """ - self.env.revert_snapshot("ready_with_3_slaves") - - self.helpers.create_cluster(name=self.__class__.__name__, - settings={'murano': True}) - - self.helpers.deploy_cluster(self.only_controllers) - - self.helpers.run_ostf(['sanity', 'smoke', 'tests_platform']) + self.env.revert_snapshot("deploy_murano_out_of_the_box") self.prepare_plugin()