Browse Source

Set report_interval to 0 for ovs agent unit tests

Unit tests are taking longer than usual since [1] and
causing timeouts in unit tests jobs intermittently. Set
report_interval(as this is now used to set RPC timeout)
to 0 so report_state responds immediately.

[1] https://review.opendev.org/q/I8a95e80ca74edc8f8f394cefc749c4065a8e0575

Related-Bug: #1948676
Change-Id: I653c907a4323e19d5bc381cd3716d42c45a75e15
(cherry picked from commit a4ffd1a2f9)
changes/77/819177/1
yatinkarel 6 months ago committed by yatin
parent
commit
8439348add
  1. 4
      neutron/tests/unit/plugins/ml2/drivers/openvswitch/agent/test_ovs_neutron_agent.py

4
neutron/tests/unit/plugins/ml2/drivers/openvswitch/agent/test_ovs_neutron_agent.py

@ -128,6 +128,8 @@ class TestOvsNeutronAgent(object):
cfg.CONF.set_default('quitting_rpc_timeout', 10, 'AGENT')
cfg.CONF.set_default('local_ip', '127.0.0.1', 'OVS')
cfg.CONF.set_default('host', 'host')
# Set report_interval to 0 so rpc calls responds immediately
cfg.CONF.set_override('report_interval', 0, 'AGENT')
mock.patch(
'neutron.agent.ovsdb.native.helpers.enable_connection_uri').start()
mock.patch(
@ -3029,6 +3031,8 @@ class TestOvsDvrNeutronAgent(object):
cfg.CONF.set_default('firewall_driver',
'neutron.agent.firewall.NoopFirewallDriver',
group='SECURITYGROUP')
# Set report_interval to 0 so rpc calls responds immediately
cfg.CONF.set_override('report_interval', 0, 'AGENT')
mock.patch('neutron.agent.common.ovs_lib.BaseOVS.config',
new_callable=mock.PropertyMock,

Loading…
Cancel
Save