From b10f0a7990b916aebf73291e3807cb7eff5fc5ca Mon Sep 17 00:00:00 2001 From: Chandan Purushothama Date: Wed, 22 Oct 2014 12:09:52 -0700 Subject: [PATCH] CLOUDSTACK-7769 - Fixed test_ssvm.py script --- test/integration/smoke/test_ssvm.py | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/test/integration/smoke/test_ssvm.py b/test/integration/smoke/test_ssvm.py index 5713569e4ff..ed9eab08c2d 100644 --- a/test/integration/smoke/test_ssvm.py +++ b/test/integration/smoke/test_ssvm.py @@ -157,8 +157,16 @@ class TestSSVMs(cloudstackTestCase): "Check list response returns a valid list" ) iprange = ipranges_response[0] - - self.assertEqual( + + #Fetch corresponding Physical Network of SSVM's Zone + listphyntwk = PhysicalNetwork.list( + self.apiclient, + zoneid=ssvm.zoneid + ) + + # Execute the following assertion in all zones except EIP-ELB Zones + if not (self.zone.networktype.lower() == 'basic' and isinstance(NetScaler.list(self.apiclient,physicalnetworkid=listphyntwk[0].id), list) is True): + self.assertEqual( ssvm.gateway, iprange.gateway, "Check gateway with that of corresponding ip range" @@ -274,7 +282,15 @@ class TestSSVMs(cloudstackTestCase): ) iprange = ipranges_response[0] - self.assertEqual( + #Fetch corresponding Physical Network of SSVM's Zone + listphyntwk = PhysicalNetwork.list( + self.apiclient, + zoneid=cpvm.zoneid + ) + + # Execute the following assertion in all zones except EIP-ELB Zones + if not (self.zone.networktype.lower() == 'basic' and isinstance(NetScaler.list(self.apiclient,physicalnetworkid=listphyntwk[0].id), list) is True): + self.assertEqual( cpvm.gateway, iprange.gateway, "Check gateway with that of corresponding ip range"