cleanup is non-optional

This commit is contained in:
meejah 2020-05-10 22:05:47 -06:00
parent 0540df8ab1
commit 9a62b1f93f
2 changed files with 4 additions and 5 deletions

View File

@ -172,7 +172,7 @@ def test_reject_storage_server(reactor, request, temp_dir, flog_gatherer):
storage0.process.transport.signalProcess('TERM')
yield storage0.protocol.exited
yield util._run_node(
reactor, storage0.process.node_dir, request, None, cleanup=False,
reactor, storage0.process.node_dir, request, None,
)
yield util.await_client_ready(diana, servers=2)
@ -189,7 +189,7 @@ def test_reject_storage_server(reactor, request, temp_dir, flog_gatherer):
yield diana.transport._protocol.exited
diana = yield util._run_node(
reactor, diana._node_dir, request, None, cleanup=False,
reactor, diana._node_dir, request, None,
)
yield util.await_client_ready(diana, servers=2)

View File

@ -210,7 +210,7 @@ class TahoeProcess(object):
return "<TahoeProcess in '{}'>".format(self._node_dir)
def _run_node(reactor, node_dir, request, magic_text, cleanup=True):
def _run_node(reactor, node_dir, request, magic_text):
"""
Run a tahoe process from its node_dir.
@ -236,8 +236,7 @@ def _run_node(reactor, node_dir, request, magic_text, cleanup=True):
)
transport.exited = protocol.exited
if cleanup:
request.addfinalizer(partial(_cleanup_tahoe_process, transport, protocol.exited))
request.addfinalizer(partial(_cleanup_tahoe_process, transport, protocol.exited))
# XXX abusing the Deferred; should use .when_magic_seen() pattern