Merge "Improve readability of MagicMock use in RYU test"

This commit is contained in:
Jenkins 2014-06-09 02:19:31 +00:00 committed by Gerrit Code Review
commit 4041dacc3e
1 changed files with 1 additions and 4 deletions

View File

@ -38,10 +38,7 @@ class RyuSecurityGroupsTestCase(test_sg.SecurityGroupDBTestCase):
def setUp(self, plugin=None):
test_sg_rpc.set_firewall_driver(test_sg_rpc.FIREWALL_HYBRID_DRIVER)
self.fake_ryu = fake_ryu.patch_fake_ryu_client().start()
notifier_p = mock.patch(NOTIFIER)
notifier_cls = notifier_p.start()
self.notifier = mock.Mock()
notifier_cls.return_value = self.notifier
self.notifier = mock.patch(NOTIFIER).start().return_value
self._attribute_map_bk_ = {}
for item in attributes.RESOURCE_ATTRIBUTE_MAP:
self._attribute_map_bk_[item] = (attributes.