The functional tests for agents were patching ip_lib in the
function to configure an agent, so any tests that relied on
multiple agents would patch ip_lib multiple times.
Partial-Bug: #
1468998
Change-Id: Ibccf586dea870ec222369c0876f17f8eaf9a1aca
self.mock_plugin_api = mock.patch(
'neutron.agent.l3.agent.L3PluginApi').start().return_value
mock.patch('neutron.agent.rpc.PluginReportStateAPI').start()
+ mock.patch.object(ip_lib, '_arping').start()
self.agent = self._configure_agent('agent1')
def _get_config_opts(self):
get_temp_file_path('external/pids'))
conf.set_override('host', host)
agent = neutron_l3_agent.L3NATAgentWithStateReport(host, conf)
- mock.patch.object(ip_lib, '_arping').start()
return agent