diff --git a/tools/marvin/marvin/jsonHelper.py b/tools/marvin/marvin/jsonHelper.py index 605e06f7348..a395e6ba981 100644 --- a/tools/marvin/marvin/jsonHelper.py +++ b/tools/marvin/marvin/jsonHelper.py @@ -113,10 +113,6 @@ def finalizeResultObj(result, responseName, responsecls): responsecls) return result elif responsecls is not None: - for k, v in result.__dict__.iteritems(): - if k in responsecls.__dict__: - return result - attr = result.__dict__.keys()[0] value = getattr(result, attr) diff --git a/tools/marvin/marvin/test/test_factories.py b/tools/marvin/marvin/test/test_factories.py index 89d67fb759b..6a093036982 100644 --- a/tools/marvin/marvin/test/test_factories.py +++ b/tools/marvin/marvin/test/test_factories.py @@ -229,11 +229,9 @@ class IpAddressFactoryTest(unittest.TestCase): account=accnt.name, domainid=accnt.domainid) - all_ips = IpAddress.listPublic(apiclient=self.apiClient) - firstip = all_ips[0] networks = Network.list(apiclient=self.apiClient, account = accnt.name, domainid = accnt.domainid) - firstip.associate(apiclient=self.apiClient, networkid = networks[0].id) + IpAddress(apiclient=self.apiClient, networkid = networks[0].id) class FirewallRuleFactoryTest(unittest.TestCase): @@ -280,7 +278,7 @@ class FirewallRuleFactoryTest(unittest.TestCase): fwrule = SshFirewallRuleFactory( apiclient=self.apiClient, - ipaddressid=ipaddress.ipaddress.id + ipaddressid=ipaddress.id ) fwrule |should_not| be(None) fwrule |should| be_instance_of(Firewall)