Skip to content

Commit

Permalink
tests: drop usage of SecurityGroupServerRpcApiMixin
Browse files Browse the repository at this point in the history
Drop usage of SecurityGroupServerRpcApiMixin in the unit tests.
This is required to be able to eventually move this API into a
messaging namespace.  It needs to use its own messaging client
instance, instead of a different one it gets after being used as a
mixin.

Part of blueprint rpc-docs-and-namespaces.

Change-Id: I2b66545ebfe5e7acf0a89fac58dc22e72d0df099
  • Loading branch information
russellb committed Jan 21, 2015
1 parent c30ca3f commit b4d8c3b
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions neutron/tests/unit/test_security_groups_rpc.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
from neutron.agent.common import config
from neutron.agent import firewall as firewall_base
from neutron.agent.linux import iptables_manager
from neutron.agent import rpc as agent_rpc
from neutron.agent import securitygroups_rpc as sg_rpc
from neutron.api.rpc.handlers import securitygroups_rpc
from neutron.common import constants as const
Expand Down Expand Up @@ -1604,14 +1603,9 @@ def test_setup_port_filters_with_global_refresh(self):
self.assertFalse(self.agent.prepare_devices_filter.called)


class FakeSGRpcApi(agent_rpc.PluginApi,
sg_rpc.SecurityGroupServerRpcApiMixin):
pass


class SecurityGroupServerRpcApiTestCase(base.BaseTestCase):
def test_security_group_rules_for_devices(self):
rpcapi = FakeSGRpcApi('fake_topic')
rpcapi = sg_rpc.SecurityGroupServerRpcApi('fake_topic')

with contextlib.nested(
mock.patch.object(rpcapi.client, 'call'),
Expand Down

0 comments on commit b4d8c3b

Please sign in to comment.