Skip to content

Commit

Permalink
tests: Allow closed http server in assert_start_raises_init_error
Browse files Browse the repository at this point in the history
  • Loading branch information
ken2812221 committed Oct 8, 2018
1 parent f504a14 commit 62c304e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/functional/test_framework/test_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,9 @@ def wait_for_rpc_connection(self):
if e.errno != errno.ECONNREFUSED: # Port not yet open?
raise # unknown IO error
except JSONRPCException as e: # Initialization phase
if e.error['code'] != -28: # RPC in warmup?
# -28 RPC in warmup
# -342 Service unavailable, RPC server started but is shutting down due to error
if e.error['code'] != -28 and e.error['code'] != -342:
raise # unknown JSON RPC exception
except ValueError as e: # cookie file not found and no rpcuser or rpcassword. bitcoind still starting
if "No RPC credentials" not in str(e):
Expand Down

0 comments on commit 62c304e

Please sign in to comment.