mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-06-06 13:10:09 +02:00
test: Fix intermittent failure in wallet_basic.py
There could be a race with outstanding TxAddedToMempool notifications being applied to the soon-to-be created wallet. Fixes an intermittent timeout reproducable by adding a sleep to AddToWallet.
This commit is contained in:
parent
3edf400b10
commit
07350e204d
@ -603,6 +603,8 @@ class WalletTest(BitcoinTestFramework):
|
||||
txid_a = self.nodes[0].sendtoaddress(addr_a, 0.01)
|
||||
txid_b = self.nodes[0].sendtoaddress(addr_b, 0.01)
|
||||
self.generate(self.nodes[0], 1, sync_fun=self.no_op)
|
||||
# Prevent race of listunspent with outstanding TxAddedToMempool notifications
|
||||
self.nodes[0].syncwithvalidationinterfacequeue()
|
||||
# Now import the descriptors, make sure we can identify on which descriptor each coin was received.
|
||||
self.nodes[0].createwallet(wallet_name="wo", descriptors=True, disable_private_keys=True)
|
||||
wo_wallet = self.nodes[0].get_wallet_rpc("wo")
|
||||
|
Loading…
x
Reference in New Issue
Block a user