[chronik-client] Move appendWsUrls out of the class as a public function
Summary:
Move appendWsUrls out of FailoverProxy class and export as an independent function.
Rationale:
Code simplification - the function does not depend on any internal state of FailoverProxy
Make the function reusable outside FailoverProxy scope, especially in the new node selection (ping) feature
Regarding function location:
Although the function is separated from the class, keeping it in failoverProxy.ts is reasonable because:
The function was originally designed to handle proxy URLs and is closely tied to the Endpoint interface, which is still defined in failoverProxy.ts
Note: The function is only used in tests, not found in other directories, so only need to adjust the import in test.ts.
Test Plan: npm test
Reviewers: Fabien, bytesofman, emack, O1 Bitcoin ABC, #bitcoin_abc
Reviewed By: Fabien, O1 Bitcoin ABC, #bitcoin_abc
Subscribers: Fabien
Differential Revision: https://reviews.bitcoinabc.org/D17935