Merge "Mock check if ipv6 is enabled in L3 agent unit tests" into stable/queens

This commit is contained in:
Zuul 2020-02-25 05:31:40 +00:00 committed by Gerrit Code Review
commit 600af52d57
1 changed files with 5 additions and 1 deletions

View File

@ -289,7 +289,11 @@ class TestBasicRouterOperations(BasicRouterOperationsFramework):
destroy_metadata_proxy.assert_not_called() destroy_metadata_proxy.assert_not_called()
def _test__configure_ipv6_params_helper(self, state, gw_port_id): def _test__configure_ipv6_params_helper(self, state, gw_port_id):
agent = l3_agent.L3NATAgent(HOSTNAME, self.conf) with mock.patch(
'neutron.common.ipv6_utils.is_enabled_and_bind_by_default',
return_value=True):
agent = l3_agent.L3NATAgent(HOSTNAME, self.conf)
router_info = l3router.RouterInfo(agent, _uuid(), {}, **self.ri_kwargs) router_info = l3router.RouterInfo(agent, _uuid(), {}, **self.ri_kwargs)
if gw_port_id: if gw_port_id:
router_info.ex_gw_port = {'id': gw_port_id} router_info.ex_gw_port = {'id': gw_port_id}