Merge #14413: tests: Allow closed rpc handler in assert_start_raises_init_error
Summary:
62c304ea48 tests: Allow closed http server in assert_start_raises_init_error (Chun Kuan Lee)
Pull request description:
The rpc handler may be unregistered when http server haven't been closed yet. So it may be allowable to get -342 `non-JSON HTTP response with \'%i %s\' from server` (503 Service Unavailable) See https://ci.appveyor.com/project/DrahtBot/bitcoin/build/master.2001. It shows "Rejecting request while shutting down" between "RPC stopped" and "Stopped HTTP server"
Tree-SHA512: e1f50ab9096cf23494ccc2850c01516c4a75f112c99108759157b22fce2011682a4b88216f206702f6a56e960182c00098053ad75f13aa0eafe27046adae63da
Backport of Core PR14413
https://github.com/bitcoin/bitcoin/pull/14413/files
Test Plan:
test_runner.py
Reviewers: #bitcoin_abc, deadalnix
Reviewed By: #bitcoin_abc, deadalnix
Differential Revision: https://reviews.bitcoinabc.org/D5011