Fix redundant router deployment tests

Signed-off-by: Prasanna Santhanam <tsp@apache.org>
This commit is contained in:
Prasanna Santhanam 2013-08-09 12:08:16 +05:30
parent bad72a0aeb
commit b3fb75e6c6

View File

@ -196,7 +196,7 @@ class TestRvRDeploymentPlanning(cloudstackTestCase):
try:
cleanup_resources(self.apiclient, self.cleanup)
except Exception as e:
self.debug("Warning: Exception during cleanup : %s" % e)
self.warn("Warning: Exception during cleanup : %s" % e)
#raise Exception("Warning: Exception during cleanup : %s" % e)
return
@ -391,7 +391,7 @@ class TestRvRDeploymentPlanning(cloudstackTestCase):
cmd.allocationstate = 'Disabled'
self.apiclient.updatePod(cmd)
self.debug("Warning: Disabled all pods in zone")
self.warn("Warning: Disabled all pods in zone")
cmd = updatePod.updatePodCmd()
cmd.id = pods[0].id
@ -528,6 +528,7 @@ class TestRvRDeploymentPlanning(cloudstackTestCase):
allocationstate="Disabled"
)
if pods is not None:
for pod in pods:
cmd = updatePod.updatePodCmd()
cmd.id = pod.id
@ -611,7 +612,7 @@ class TestRvRDeploymentPlanning(cloudstackTestCase):
cmd.allocationstate = 'Disabled'
self.apiclient.updatePod(cmd)
self.debug("Warning: Disabled all pods in zone")
self.warn("Warning: Disabled all pods in zone")
cmd = updatePod.updatePodCmd()
cmd.id = pods[0].id
@ -627,7 +628,7 @@ class TestRvRDeploymentPlanning(cloudstackTestCase):
cmd.allocationstate = 'Disabled'
self.apiclient.updateCluster(cmd)
self.debug("Warning: Disabled all pods in zone")
self.warn("Warning: Disabled all pods in zone")
cmd = updateCluster.updateClusterCmd()
cmd.id = clusters[0].id
@ -751,12 +752,7 @@ class TestRvRDeploymentPlanning(cloudstackTestCase):
listall=True,
allocationstate="Disabled"
)
self.assertEqual(
isinstance(pods, list),
True,
"List pods should not return an empty response"
)
if pods is not None:
for pod in pods:
cmd = updatePod.updatePodCmd()
cmd.id = pod.id
@ -770,6 +766,7 @@ class TestRvRDeploymentPlanning(cloudstackTestCase):
listall=True
)
if clusters is not None:
for cluster in clusters:
cmd = updateCluster.updateClusterCmd()
cmd.id = cluster.id
@ -852,7 +849,7 @@ class TestRvRDeploymentPlanning(cloudstackTestCase):
cmd.allocationstate = 'Disabled'
self.apiclient.updatePod(cmd)
self.debug("Warning: Disabled all pods in zone")
self.warn("Warning: Disabled all pods in zone")
cmd = updatePod.updatePodCmd()
cmd.id = pods[0].id
@ -868,7 +865,7 @@ class TestRvRDeploymentPlanning(cloudstackTestCase):
cmd.allocationstate = 'Disabled'
self.apiclient.updateCluster(cmd)
self.debug("Warning: Disabled all pods in zone")
self.warn("Warning: Disabled all pods in zone")
cmd = updateCluster.updateClusterCmd()
cmd.id = clusters[0].id