mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-04-29 14:59:39 -04:00
test: Avoid redundant stop and error spam on startup failure
Trying to immediately shut down a node after a startup failure without waiting for the RPC to be fully up will in most cases just fail and lead to an RPC error. Also, it is confusing to sidestep the existing fallback to kill any leftover nodes on a test failure. So just rely on the fallback.
This commit is contained in:
parent
fa0dc09b90
commit
fae3bf6b87
1 changed files with 4 additions and 9 deletions
|
@ -567,15 +567,10 @@ class BitcoinTestFramework(metaclass=BitcoinTestMetaClass):
|
||||||
if extra_args is None:
|
if extra_args is None:
|
||||||
extra_args = [None] * self.num_nodes
|
extra_args = [None] * self.num_nodes
|
||||||
assert_equal(len(extra_args), self.num_nodes)
|
assert_equal(len(extra_args), self.num_nodes)
|
||||||
try:
|
for i, node in enumerate(self.nodes):
|
||||||
for i, node in enumerate(self.nodes):
|
node.start(extra_args[i], *args, **kwargs)
|
||||||
node.start(extra_args[i], *args, **kwargs)
|
for node in self.nodes:
|
||||||
for node in self.nodes:
|
node.wait_for_rpc_connection()
|
||||||
node.wait_for_rpc_connection()
|
|
||||||
except Exception:
|
|
||||||
# If one node failed to start, stop the others
|
|
||||||
self.stop_nodes()
|
|
||||||
raise
|
|
||||||
|
|
||||||
if self.options.coveragedir is not None:
|
if self.options.coveragedir is not None:
|
||||||
for node in self.nodes:
|
for node in self.nodes:
|
||||||
|
|
Loading…
Add table
Reference in a new issue