Repository: cloudstack
Updated Branches:
  refs/heads/master 37baddd72 -> d75961d97


CLOUDSTACK-7192: Skip tests on Hyper-V which don't apply


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

Branch: refs/heads/master
Commit: d75961d973021fbfec5058d907923f885ac8906a
Parents: 37baddd
Author: John Dilley <john.dil...@citrix.com>
Authored: Tue Aug 5 10:23:21 2014 +0000
Committer: sanjeev <sanj...@apache.org>
Committed: Tue Aug 12 16:49:56 2014 +0530

----------------------------------------------------------------------
 test/integration/smoke/test_nic.py             | 4 ++++
 test/integration/smoke/test_primary_storage.py | 7 +++++++
 test/integration/smoke/test_scale_vm.py        | 4 ++--
 test/integration/smoke/test_snapshots.py       | 4 ++++
 test/integration/smoke/test_vm_snapshots.py    | 4 ++--
 test/integration/smoke/test_volumes.py         | 8 ++++----
 6 files changed, 23 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/d75961d9/test/integration/smoke/test_nic.py
----------------------------------------------------------------------
diff --git a/test/integration/smoke/test_nic.py 
b/test/integration/smoke/test_nic.py
index dd6de96..488ed0a 100644
--- a/test/integration/smoke/test_nic.py
+++ b/test/integration/smoke/test_nic.py
@@ -40,6 +40,10 @@ class TestNic(cloudstackTestCase):
         # assign the signal handler immediately
         signal.signal(signal.SIGINT, signal_handler)
 
+        hypervisor = self.testClient.getHypervisorInfo()
+        if hypervisor.lower() == "hyperv":
+            raise unittest.SkipTest("Not supported on Hyper-V")
+
         try:
             self.apiclient = self.testClient.getApiClient()
             self.dbclient  = self.testClient.getDbConnection()

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/d75961d9/test/integration/smoke/test_primary_storage.py
----------------------------------------------------------------------
diff --git a/test/integration/smoke/test_primary_storage.py 
b/test/integration/smoke/test_primary_storage.py
index 66aec59..8926a9e 100644
--- a/test/integration/smoke/test_primary_storage.py
+++ b/test/integration/smoke/test_primary_storage.py
@@ -56,6 +56,10 @@ class TestPrimaryStorageServices(cloudstackTestCase):
         """Test primary storage pools - XEN, KVM, VMWare
         """
 
+        if self.testClient.getHypervisorInfo().lower() == "hyperv":
+            raise self.skipTest("NFS primary storage not supported on Hyper-V")
+
+
         # Validate the following:
         # 1. List Clusters
         # 2. verify that the cluster is in 'Enabled' allocation state
@@ -149,6 +153,9 @@ class TestPrimaryStorageServices(cloudstackTestCase):
         """Test primary storage pools - XEN, KVM, VMWare
         """
 
+        if self.testClient.getHypervisorInfo().lower() == "hyperv":
+            raise self.skipTest("iSCSI primary storage Not supported on 
Hyper-V")
+
         # Validate the following:
         # 1. List Clusters
         # 2. verify that the cluster is in 'Enabled' allocation state

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/d75961d9/test/integration/smoke/test_scale_vm.py
----------------------------------------------------------------------
diff --git a/test/integration/smoke/test_scale_vm.py 
b/test/integration/smoke/test_scale_vm.py
index b5c89be..b3804dc 100644
--- a/test/integration/smoke/test_scale_vm.py
+++ b/test/integration/smoke/test_scale_vm.py
@@ -35,8 +35,8 @@ class TestScaleVm(cloudstackTestCase):
         cls.apiclient = testClient.getApiClient()
         cls.services = testClient.getParsedTestDataConfig()
         cls.hypervisor = cls.testClient.getHypervisorInfo()
-        if cls.hypervisor.lower() == 'kvm':
-            raise unittest.SkipTest("ScaleVM is not supported on KVM. Hence, 
skipping the test")
+        if cls.hypervisor.lower() in ('kvm', 'hyperv'):
+            raise unittest.SkipTest("ScaleVM is not supported on KVM or 
Hyper-V. Hence, skipping the test")
 
         # Get Zone, Domain and templates
         domain = get_domain(cls.apiclient)

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/d75961d9/test/integration/smoke/test_snapshots.py
----------------------------------------------------------------------
diff --git a/test/integration/smoke/test_snapshots.py 
b/test/integration/smoke/test_snapshots.py
index 8b6fdd1..5db3e40 100644
--- a/test/integration/smoke/test_snapshots.py
+++ b/test/integration/smoke/test_snapshots.py
@@ -36,6 +36,10 @@ class TestSnapshotRootDisk(cloudstackTestCase):
         cls.zone = get_zone(cls.apiclient, testClient.getZoneForTests())
         cls.services['mode'] = cls.zone.networktype
 
+        cls.hypervisor = cls.testClient.getHypervisorInfo()
+        if cls.hypervisor.lower() == 'hyperv':
+            raise unittest.SkipTest("Snapshots not supported on Hyper-V")
+
         template = get_template(
                             cls.apiclient,
                             cls.zone.id,

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/d75961d9/test/integration/smoke/test_vm_snapshots.py
----------------------------------------------------------------------
diff --git a/test/integration/smoke/test_vm_snapshots.py 
b/test/integration/smoke/test_vm_snapshots.py
index 01626f5..dae945c 100644
--- a/test/integration/smoke/test_vm_snapshots.py
+++ b/test/integration/smoke/test_vm_snapshots.py
@@ -38,8 +38,8 @@ class TestVmSnapshot(cloudstackTestCase):
         testClient = super(TestVmSnapshot, cls).getClsTestClient()
 
         hypervisor = testClient.getHypervisorInfo()
-        if hypervisor.lower() == KVM.lower():
-            raise unittest.SkipTest("VM snapshot feature is not supported on 
KVM")
+        if hypervisor.lower() in (KVM.lower(), "hyperv"):
+            raise unittest.SkipTest("VM snapshot feature is not supported on 
KVM or Hyper-V")
 
         cls.apiclient = testClient.getApiClient()
         cls.services = testClient.getParsedTestDataConfig()

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/d75961d9/test/integration/smoke/test_volumes.py
----------------------------------------------------------------------
diff --git a/test/integration/smoke/test_volumes.py 
b/test/integration/smoke/test_volumes.py
index 6e9ea75..e2e0d76 100644
--- a/test/integration/smoke/test_volumes.py
+++ b/test/integration/smoke/test_volumes.py
@@ -585,8 +585,8 @@ class TestVolumes(cloudstackTestCase):
 
         if hosts[0].hypervisor == "XenServer":
             self.virtual_machine.stop(self.apiClient)
-        elif hosts[0].hypervisor.lower() == "vmware":
-            self.skipTest("Resize Volume is unsupported on VmWare")
+        elif hosts[0].hypervisor.lower() in ("vmware", "hyperv"):
+            self.skipTest("Resize Volume is unsupported on VmWare and Hyper-V")
 
         self.apiClient.resizeVolume(cmd)
         count = 0
@@ -636,8 +636,8 @@ class TestVolumes(cloudstackTestCase):
 
         if hosts[0].hypervisor == "XenServer":
             self.virtual_machine.stop(self.apiClient)
-        elif hosts[0].hypervisor.lower() == "vmware":
-            self.skipTest("Resize Volume is unsupported on VmWare")
+        elif hosts[0].hypervisor.lower() in ("vmware", "hyperv"):
+            self.skipTest("Resize Volume is unsupported on VmWare and Hyper-V")
 
         # resize the data disk
         self.debug("Resize Volume ID: %s" % self.volume.id)

Reply via email to