CLOUDSTACK-2361: fix storage xenmotion test script Signed-off-by: Prasanna Santhanam <t...@apache.org>
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/8be30443 Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/8be30443 Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/8be30443 Branch: refs/heads/object_store Commit: 8be304434e808660f17c5753abbf455a49ed7602 Parents: 93db64f Author: Talluri <srikanteswararao.tall...@citrix.com> Authored: Wed May 8 02:41:02 2013 +0530 Committer: Prasanna Santhanam <t...@apache.org> Committed: Wed May 8 14:26:43 2013 +0530 ---------------------------------------------------------------------- test/integration/component/test_storage_motion.py | 17 +++++++++++++-- 1 files changed, 14 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/8be30443/test/integration/component/test_storage_motion.py ---------------------------------------------------------------------- diff --git a/test/integration/component/test_storage_motion.py b/test/integration/component/test_storage_motion.py index 086ec77..c05d79e 100644 --- a/test/integration/component/test_storage_motion.py +++ b/test/integration/component/test_storage_motion.py @@ -98,16 +98,16 @@ class TestStorageMotion(cloudstackTestCase): # Get Zone, Domain and templates domain = get_domain(cls.api_client, cls.services) - zone = get_zone(cls.api_client, cls.services) + cls.zone = get_zone(cls.api_client, cls.services) cls.services['mode'] = cls.zone.networktype template = get_template( cls.api_client, - zone.id, + cls.zone.id, cls.services["ostype"] ) # Set Zones and disk offerings - cls.services["small"]["zoneid"] = zone.id + cls.services["small"]["zoneid"] = cls.zone.id cls.services["small"]["template"] = template.id # Create VMs, NAT Rules etc @@ -258,6 +258,17 @@ class TestStorageMotion(cloudstackTestCase): self.apiclient, id=volume.id ) + self.assertEqual( + isinstance(pools, list), + True, + "Check list storage pools response for valid list" + ) + self.assertNotEqual( + pools, + None, + "Check if pools exists in ListStoragePools" + ) + pool = pools[0] self.debug("Migrating Volume-ID: %s to Pool: %s" % ( volume.id,