Add bitcoincash support for prepare and run scripts, add bitcoincash to testing suite, groundwork for bch-xmr atomic swap protocol

This commit is contained in:
mainnet-pat
2024-10-07 16:48:24 +00:00
committed by tecnovert
parent 745d1460e5
commit 1b43806d51
20 changed files with 937 additions and 9 deletions

View File

@@ -251,6 +251,7 @@ class BasicSwap(BaseApp):
protocolInterfaces = {
SwapTypes.SELLER_FIRST: atomic_swap_1.AtomicSwapInterface(),
SwapTypes.XMR_SWAP: xmr_swap_1.XmrSwapInterface(),
SwapTypes.XMR_BCH_SWAP: xmr_swap_1.XmrBchSwapInterface(),
}
def __init__(self, fp, data_dir, settings, chain, log_name='BasicSwap', transient_instance=False):
@@ -688,6 +689,9 @@ class BasicSwap(BaseApp):
elif coin == Coins.BTC:
from .interface.btc import BTCInterface
return BTCInterface(self.coin_clients[coin], self.chain, self)
elif coin == Coins.BCH:
from .interface.bch import BCHInterface
return BCHInterface(self.coin_clients[coin], self.chain, self)
elif coin == Coins.LTC:
from .interface.ltc import LTCInterface, LTCInterfaceMWEB
interface = LTCInterface(self.coin_clients[coin], self.chain, self)