Merge "Refresh rpc_backend values in unit tests to those from oslo.messaging"

This commit is contained in:
Jenkins 2014-08-25 10:16:16 +00:00 committed by Gerrit Code Review
commit 8fde2e37f0
13 changed files with 2 additions and 32 deletions

View File

@ -18,7 +18,7 @@ api_extensions_path = unit/extensions
api_paste_config = api-paste.ini.test
# The messaging module to use, defaults to kombu.
rpc_backend = neutron.openstack.common.rpc.impl_fake
rpc_backend = fake
lock_path = $state_path/lock

View File

@ -36,9 +36,6 @@ class TestHyperVNeutronAgent(base.BaseTestCase):
def setUp(self):
super(TestHyperVNeutronAgent, self).setUp()
# Avoid rpc initialization for unit tests
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
utilsfactory._get_windows_version = mock.MagicMock(
return_value='6.2.0')

View File

@ -59,9 +59,6 @@ class TestSdnveNeutronAgent(base.BaseTestCase):
notifier_cls = notifier_p.start()
self.notifier = mock.Mock()
notifier_cls.return_value = self.notifier
# Avoid rpc initialization for unit tests
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
cfg.CONF.set_override('integration_bridge',
'br_int', group='SDNVE')
kwargs = sdnve_neutron_agent.create_agent_config_map(cfg.CONF)

View File

@ -95,8 +95,6 @@ class TestLinuxBridgeAgent(base.BaseTestCase):
super(TestLinuxBridgeAgent, self).setUp()
# disable setting up periodic state reporting
cfg.CONF.set_override('report_interval', 0, 'AGENT')
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
cfg.CONF.set_default('firewall_driver',
'neutron.agent.firewall.NoopFirewallDriver',
group='SECURITYGROUP')

View File

@ -66,9 +66,6 @@ class TestEswitchAgent(base.BaseTestCase):
def setUp(self):
super(TestEswitchAgent, self).setUp()
# Avoid rpc initialization for unit tests
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
cfg.CONF.set_default('firewall_driver',
'neutron.agent.firewall.NoopFirewallDriver',
group='SECURITYGROUP')

View File

@ -33,8 +33,6 @@ class TestMlnxPluginConfig(testlib_api.SqlTestCase):
def setUp(self):
super(TestMlnxPluginConfig, self).setUp()
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
cfg.CONF.set_override(group='MLNX',
name='network_vlan_ranges',
override=self.config_vlan_ranges)

View File

@ -39,8 +39,6 @@ class TestNecAgentBase(base.BaseTestCase):
cfg.CONF.set_default('firewall_driver',
'neutron.agent.firewall.NoopFirewallDriver',
group='SECURITYGROUP')
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
cfg.CONF.set_override('host', 'dummy-host')
with contextlib.nested(
mock.patch.object(ovs_lib.OVSBridge, 'get_datapath_id',

View File

@ -192,9 +192,6 @@ class TestOFANeutronAgent(ofa_test_base.OFAAgentTestBase):
notifier_cls = notifier_p.start()
self.notifier = mock.Mock()
notifier_cls.return_value = self.notifier
# Avoid rpc initialization for unit tests
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
kwargs = self.mod_agent.create_agent_config_map(cfg.CONF)
class MockFixedIntervalLoopingCall(object):

View File

@ -36,8 +36,6 @@ class TestOneConvergenceAgentBase(base.BaseTestCase):
cfg.CONF.set_default('firewall_driver',
'neutron.agent.firewall.NoopFirewallDriver',
group='SECURITYGROUP')
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
with contextlib.nested(
mock.patch('neutron.openstack.common.loopingcall.'
'FixedIntervalLoopingCall'),

View File

@ -105,9 +105,6 @@ class TestOvsNeutronAgent(base.BaseTestCase):
cfg.CONF.set_default('firewall_driver',
'neutron.agent.firewall.NoopFirewallDriver',
group='SECURITYGROUP')
# Avoid rpc initialization for unit tests
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
kwargs = ovs_neutron_agent.create_agent_config_map(cfg.CONF)
class MockFixedIntervalLoopingCall(object):
@ -1379,9 +1376,6 @@ class AncillaryBridgesTest(base.BaseTestCase):
cfg.CONF.set_default('firewall_driver',
'neutron.agent.firewall.NoopFirewallDriver',
group='SECURITYGROUP')
# Avoid rpc initialization for unit tests
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
cfg.CONF.set_override('report_interval', 0, 'AGENT')
self.kwargs = ovs_neutron_agent.create_agent_config_map(cfg.CONF)

View File

@ -74,8 +74,6 @@ class TunnelTest(base.BaseTestCase):
cfg.CONF.set_default('firewall_driver',
'neutron.agent.firewall.NoopFirewallDriver',
group='SECURITYGROUP')
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
cfg.CONF.set_override('report_interval', 0, 'AGENT')
self.INT_BRIDGE = 'integration_bridge'

View File

@ -29,8 +29,6 @@ class TestSriovAgent(base.BaseTestCase):
super(TestSriovAgent, self).setUp()
# disable setting up periodic state reporting
cfg.CONF.set_override('report_interval', 0, 'AGENT')
cfg.CONF.set_override('rpc_backend',
'neutron.openstack.common.rpc.impl_fake')
cfg.CONF.set_default('firewall_driver',
'neutron.agent.firewall.NoopFirewallDriver',
group='SECURITYGROUP')

View File

@ -18,7 +18,7 @@ bind_port = 9696
api_paste_config = api-paste.ini.test
# The messaging module to use, defaults to kombu.
rpc_backend = neutron.openstack.common.rpc.impl_fake
rpc_backend = fake
lock_path = $state_path/lock