You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ek...@apache.org on 2015/06/24 09:44:20 UTC

[2/2] git commit: updated refs/heads/master to da72bb9

CLOUDSTACK-8574: Skip testcases including data disk creation for LXC if storagePool type is not RBD

Signed-off-by: wilderrodrigues <wr...@schubergphilis.com>


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/6f643fc4
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/6f643fc4
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/6f643fc4

Branch: refs/heads/master
Commit: 6f643fc48690b0cdc3649f32e721221c7f0e9650
Parents: 7d70e49
Author: pritisarap12 <pr...@clogeny.com>
Authored: Fri Jun 19 16:11:46 2015 +0530
Committer: wilderrodrigues <wr...@schubergphilis.com>
Committed: Wed Jun 24 09:43:55 2015 +0200

----------------------------------------------------------------------
 test/integration/component/test_stopped_vm.py | 39 ++++++++++++++++++++--
 1 file changed, 37 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/6f643fc4/test/integration/component/test_stopped_vm.py
----------------------------------------------------------------------
diff --git a/test/integration/component/test_stopped_vm.py b/test/integration/component/test_stopped_vm.py
index de04d82..53a92bc 100644
--- a/test/integration/component/test_stopped_vm.py
+++ b/test/integration/component/test_stopped_vm.py
@@ -19,7 +19,7 @@
 """
 # Import Local Modules
 from nose.plugins.attrib import attr
-from marvin.cloudstackTestCase import cloudstackTestCase
+from marvin.cloudstackTestCase import cloudstackTestCase,unittest
 from marvin.lib.utils import cleanup_resources
 from marvin.lib.base import (Account,
                              VirtualMachine,
@@ -36,7 +36,8 @@ from marvin.lib.common import (get_zone,
                                get_domain,
                                get_template,
                                get_builtin_template_info,
-                               update_resource_limit)
+                               update_resource_limit,
+                               find_storage_pool_type)
 from marvin.codes import PASS
 
 
@@ -53,6 +54,13 @@ class TestDeployVM(cloudstackTestCase):
         cls.domain = get_domain(cls.api_client)
         cls.zone = get_zone(cls.api_client, cls.testClient.getZoneForTests())
 
+        cls.hypervisor = cls.testClient.getHypervisorInfo()
+
+        if cls.hypervisor.lower() == 'lxc':
+            if not find_storage_pool_type(cls.apiclient, storagetype='rbd'):
+                raise unittest.SkipTest("RBD storage type is required for data volumes for LXC")
+
+
         cls.template = get_template(
             cls.api_client,
             cls.zone.id,
@@ -743,6 +751,12 @@ class TestDeployHaEnabledVM(cloudstackTestCase):
 
         cls.testdata = cls.testClient.getParsedTestDataConfig()
         # Get Zone, Domain and templates
+        cls.hypervisor = cls.testClient.getHypervisorInfo()
+
+        if cls.hypervisor.lower() == 'lxc':
+            if not find_storage_pool_type(cls.apiclient, storagetype='rbd'):
+                raise unittest.SkipTest("RBD storage type is required for data volumes for LXC")
+
         cls.domain = get_domain(cls.api_client)
         cls.zone = get_zone(cls.api_client, cls.testClient.getZoneForTests())
 
@@ -946,6 +960,12 @@ class TestRouterStateAfterDeploy(cloudstackTestCase):
 
         cls.testdata = cls.testClient.getParsedTestDataConfig()
         # Get Zone, Domain and templates
+        cls.hypervisor = cls.testClient.getHypervisorInfo()
+
+        if cls.hypervisor.lower() == 'lxc':
+            if not find_storage_pool_type(cls.apiclient, storagetype='rbd'):
+                raise unittest.SkipTest("RBD storage type is required for data volumes for LXC")
+
         cls.domain = get_domain(cls.api_client)
         cls.zone = get_zone(cls.api_client, cls.testClient.getZoneForTests())
 
@@ -1102,6 +1122,12 @@ class TestDeployVMBasicZone(cloudstackTestCase):
 
         cls.testdata = cls.testClient.getParsedTestDataConfig()
         # Get Zone, Domain and templates
+        cls.hypervisor = cls.testClient.getHypervisorInfo()
+
+        if cls.hypervisor.lower() == 'lxc':
+            if not find_storage_pool_type(cls.apiclient, storagetype='rbd'):
+                raise unittest.SkipTest("RBD storage type is required for data volumes for LXC")
+
         cls.domain = get_domain(cls.api_client)
         cls.zone = get_zone(cls.api_client, cls.testClient.getZoneForTests())
 
@@ -1169,6 +1195,7 @@ class TestDeployVMFromTemplate(cloudstackTestCase):
         cls.api_client = cls.testClient.getApiClient()
 
         cls.testdata = cls.testClient.getParsedTestDataConfig()
+
         # Get Zone, Domain and templates
         cls.domain = get_domain(cls.api_client)
         cls.zone = get_zone(cls.api_client, cls.testClient.getZoneForTests())
@@ -1297,6 +1324,7 @@ class TestVMAccountLimit(cloudstackTestCase):
         cls.api_client = cls.testClient.getApiClient()
 
         cls.testdata = cls.testClient.getParsedTestDataConfig()
+
         # Get Zone, Domain and templates
         cls.domain = get_domain(cls.api_client)
         cls.zone = get_zone(cls.api_client, cls.testClient.getZoneForTests())
@@ -1419,6 +1447,12 @@ class TestUploadAttachVolume(cloudstackTestCase):
         cls.api_client = cls.testClient.getApiClient()
 
         cls.testdata = cls.testClient.getParsedTestDataConfig()
+        cls.hypervisor = cls.testClient.getHypervisorInfo()
+
+        if cls.hypervisor.lower() == 'lxc':
+            if not find_storage_pool_type(cls.apiclient, storagetype='rbd'):
+                raise unittest.SkipTest("RBD storage type is required for data volumes for LXC")
+
         # Get Zone, Domain and templates
         cls.domain = get_domain(cls.api_client)
         cls.zone = get_zone(cls.api_client, cls.testClient.getZoneForTests())
@@ -1537,6 +1571,7 @@ class TestDeployOnSpecificHost(cloudstackTestCase):
         cls.api_client = cls.testClient.getApiClient()
 
         cls.testdata = cls.testClient.getParsedTestDataConfig()
+
         # Get Zone, Domain and templates
         cls.domain = get_domain(cls.api_client)
         cls.zone = get_zone(cls.api_client, cls.testClient.getZoneForTests())