diff --git a/test/integration/component/maint/test_high_availability.py b/test/integration/component/maint/test_high_availability.py index 6fe939276f3..9e8978b66d5 100644 --- a/test/integration/component/maint/test_high_availability.py +++ b/test/integration/component/maint/test_high_availability.py @@ -20,7 +20,7 @@ """ # Import Local Modules from nose.plugins.attrib import attr -from marvin.cloudstackTestCase import cloudstackTestCase +from marvin.cloudstackTestCase import cloudstackTestCase, unittest from marvin.cloudstackAPI import (prepareHostForMaintenance, cancelHostMaintenance) from marvin.lib.utils import cleanup_resources diff --git a/test/integration/component/test_advancedsg_networks.py b/test/integration/component/test_advancedsg_networks.py index 14cd5522211..089967f79c6 100644 --- a/test/integration/component/test_advancedsg_networks.py +++ b/test/integration/component/test_advancedsg_networks.py @@ -2082,9 +2082,9 @@ class TestNetworksInAdvancedSG_VmOperations(cloudstackTestCase): # 1. VM migration should be successful #Create admin account - - if cls.hypervisor.lower() in ['lxc']: - raise unittest.SkipTest("Template creation from root volume is not supported in LXC") + self.hypervisor = self.testClient.getHypervisorInfo() + if self.hypervisor.lower() in ['lxc']: + self.skipTest("vm migrate is not supported in LXC") hosts = Host.list(self.api_client, zoneid=self.zone.id) self.assertEqual(validateList(hosts)[0], PASS, "hosts list validation failed, list is %s" % hosts) diff --git a/test/integration/component/test_base_image_updation.py b/test/integration/component/test_base_image_updation.py index 7c52e428585..c2d37c113cf 100644 --- a/test/integration/component/test_base_image_updation.py +++ b/test/integration/component/test_base_image_updation.py @@ -528,9 +528,9 @@ class TestBaseImageUpdate(cloudstackTestCase): 1) New root disk should be formed 2) The recurring snapshot rule should be deleted """ - cls.hypervisor = cls.testClient.getHypervisorInfo() - if cls.hypervisor.lower() in ['lxc']: - raise unittest.SkipTest("Template creation from root volume is not supported in LXC") + self.hypervisor = self.testClient.getHypervisorInfo() + if self.hypervisor.lower() in ['lxc']: + self.skipTest("snapshot creation is not supported in LXC") vms = VirtualMachine.list( self.apiclient, id=self.vm_with_reset.id, diff --git a/test/integration/component/test_dynamic_compute_offering.py b/test/integration/component/test_dynamic_compute_offering.py index 9d7fd9ba428..52e0cfa6b4f 100644 --- a/test/integration/component/test_dynamic_compute_offering.py +++ b/test/integration/component/test_dynamic_compute_offering.py @@ -1262,7 +1262,7 @@ class TestAccountLimits(cloudstackTestCase): # Fill services from the external config file cls.services = cloudstackTestClient.getParsedTestDataConfig() - cls.hypervisor = self.testClient.getHypervisorInfo() + cls.hypervisor = cls.testClient.getHypervisorInfo() if cls.hypervisor.lower() in ['lxc']: raise unittest.SkipTest("dynamic scaling feature is not supported on %s" % cls.hypervisor.lower()) @@ -1602,7 +1602,7 @@ class TestAffinityGroup(cloudstackTestCase): # Fill services from the external config file cls.services = cloudstackTestClient.getParsedTestDataConfig() - cls.hypervisor = self.testClient.getHypervisorInfo() + cls.hypervisor = cls.testClient.getHypervisorInfo() if cls.hypervisor.lower() in ['lxc']: raise unittest.SkipTest("dynamic scaling feature is not supported on %s" % cls.hypervisor.lower()) diff --git a/test/integration/component/test_escalations_instances.py b/test/integration/component/test_escalations_instances.py index 5dfc7c6eb87..4b2201607e6 100644 --- a/test/integration/component/test_escalations_instances.py +++ b/test/integration/component/test_escalations_instances.py @@ -2687,7 +2687,7 @@ class TestInstances(cloudstackTestCase): """ self.hypervisor = self.testClient.getHypervisorInfo() if self.hypervisor.lower() == 'lxc': - if not find_storage_pool_type(cls.api_client, storagetype='rbd'): + if not find_storage_pool_type(self.api_client, storagetype='rbd'): self.skipTest("RBD storage type is required for data volumes for LXC") # Listing all the VM's for a User list_vms_before = VirtualMachine.list( diff --git a/test/integration/component/test_project_resources.py b/test/integration/component/test_project_resources.py index 6da36ae3f96..142b08c649c 100644 --- a/test/integration/component/test_project_resources.py +++ b/test/integration/component/test_project_resources.py @@ -18,7 +18,7 @@ """ #Import Local Modules from nose.plugins.attrib import attr -from marvin.cloudstackTestCase import cloudstackTestCase +from marvin.cloudstackTestCase import cloudstackTestCase, unittest from marvin.lib.base import (VirtualMachine, Account, Project, diff --git a/test/integration/component/test_ps_domain_limits.py b/test/integration/component/test_ps_domain_limits.py index 587940025ad..d9c10184a6e 100644 --- a/test/integration/component/test_ps_domain_limits.py +++ b/test/integration/component/test_ps_domain_limits.py @@ -39,7 +39,8 @@ from marvin.lib.common import (get_domain, get_template, createSnapshotFromVirtualMachineVolume, isVmExpunged, - isDomainResourceCountEqualToExpectedCount) + isDomainResourceCountEqualToExpectedCount, + find_storage_pool_type) from marvin.lib.utils import (cleanup_resources) from marvin.codes import (PASS, FAIL, diff --git a/test/integration/component/test_volumes.py b/test/integration/component/test_volumes.py index 309d80b3c4f..1b01e777227 100644 --- a/test/integration/component/test_volumes.py +++ b/test/integration/component/test_volumes.py @@ -18,7 +18,7 @@ """ # Import Local Modules from nose.plugins.attrib import attr -from marvin.cloudstackTestCase import cloudstackTestCase +from marvin.cloudstackTestCase import cloudstackTestCase, unittest from marvin.cloudstackAPI import (listHypervisorCapabilities, attachIso, deleteVolume) diff --git a/test/integration/smoke/test_disk_offerings.py b/test/integration/smoke/test_disk_offerings.py index bf89ee3ef29..75f2452c084 100644 --- a/test/integration/smoke/test_disk_offerings.py +++ b/test/integration/smoke/test_disk_offerings.py @@ -24,6 +24,7 @@ from marvin.lib.utils import * from marvin.lib.base import * from marvin.lib.common import * from nose.plugins.attrib import attr +import pdb _multiprocess_shared_ = True @@ -45,7 +46,7 @@ class TestCreateDiskOffering(cloudstackTestCase): raise Exception("Warning: Exception during cleanup : %s" % e) return - @attr(tags = ["advanced", "basic", "eip", "sg", "advancedns", "smoke"], required_hardware="false") + @attr(tags = ["advanced", "basic", "eip", "sg", "advancedns", "smoke", "test"], required_hardware="false") def test_01_create_disk_offering(self): """Test to create disk offering @@ -65,6 +66,7 @@ class TestCreateDiskOffering(cloudstackTestCase): self.apiclient, id=disk_offering.id ) + pdb.set_trace() self.assertEqual( isinstance(list_disk_response, list), True, diff --git a/test/integration/testpaths/testpath_volumelifecycle.py b/test/integration/testpaths/testpath_volumelifecycle.py index c5a537ff0f4..6e566970317 100644 --- a/test/integration/testpaths/testpath_volumelifecycle.py +++ b/test/integration/testpaths/testpath_volumelifecycle.py @@ -17,7 +17,7 @@ """Utilities functions """ # All tests inherit from cloudstackTestCase -from marvin.cloudstackTestCase import cloudstackTestCase +from marvin.cloudstackTestCase import cloudstackTestCase, unittest # Import Integration Libraries from marvin.codes import FAILED, PASS # base - contains all resources as entities and defines create, delete, diff --git a/tools/marvin/marvin/deployDataCenter.py b/tools/marvin/marvin/deployDataCenter.py index 85057d2f9f3..5716de3861f 100644 --- a/tools/marvin/marvin/deployDataCenter.py +++ b/tools/marvin/marvin/deployDataCenter.py @@ -243,8 +243,12 @@ class DeployDataCenters(object): primarycmd.podid = podId primarycmd.tags = primary.tags primarycmd.url = primary.url + if primary.scope.lower() == 'zone': + primarycmd.scope = primary.scope + else: + primarycmd.clusterid = clusterId primarycmd.zoneid = zoneId - primarycmd.clusterid = clusterId + ret = self.__apiClient.createStoragePool(primarycmd) if ret.id: self.__tcRunLogger.debug(