Python 3: fix neutron.tests.unit.agent.linux.test_async_process
In Python 3, one cannot compare an integer to None. Change-Id: I8de3ea3752be837540ea65f1bb254a095927de44 Blueprint: neutron-python3
This commit is contained in:
parent
11c0900dea
commit
6226fb73a4
|
@ -181,7 +181,10 @@ class AsyncProcess(object):
|
|||
"""Kill the async process and respawn if necessary."""
|
||||
LOG.debug('Halting async process [%s] in response to an error.',
|
||||
self.cmd)
|
||||
respawning = self.respawn_interval >= 0
|
||||
if self.respawn_interval is not None and self.respawn_interval >= 0:
|
||||
respawning = True
|
||||
else:
|
||||
respawning = False
|
||||
self._kill(respawning=respawning)
|
||||
if respawning:
|
||||
eventlet.sleep(self.respawn_interval)
|
||||
|
|
1
tox.ini
1
tox.ini
|
@ -200,6 +200,7 @@ commands = python -m testtools.run \
|
|||
neutron.tests.unit.agent.linux.test_ip_monitor \
|
||||
neutron.tests.unit.agent.linux.test_iptables_manager \
|
||||
neutron.tests.unit.agent.linux.test_external_process \
|
||||
neutron.tests.unit.agent.linux.test_async_process \
|
||||
neutron.tests.unit.agent.linux.test_ovsdb_monitor \
|
||||
neutron.tests.unit.agent.linux.test_bridge_lib \
|
||||
neutron.tests.unit.agent.linux.test_ip_link_support \
|
||||
|
|
Loading…
Reference in New Issue