aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2021-12-24 12:03:38 +0100
committerMarcoFalke <falke.marco@gmail.com>2021-12-24 12:03:21 +0100
commitfa0ac9d7e36ec616cd673b9041f0e54b9f32d5b0 (patch)
tree4b7afaef6ccc3147d4f1e5e47e9b083934042a17 /test
parent369978686e156ad34df703f1e60bd90aeaa8f2d6 (diff)
downloadbitcoin-fa0ac9d7e36ec616cd673b9041f0e54b9f32d5b0.tar.xz
test: Fix rpc_scantxoutset intermittent issue
Diffstat (limited to 'test')
-rwxr-xr-xtest/functional/rpc_scantxoutset.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/test/functional/rpc_scantxoutset.py b/test/functional/rpc_scantxoutset.py
index 8703bfab8e..37a9baf482 100755
--- a/test/functional/rpc_scantxoutset.py
+++ b/test/functional/rpc_scantxoutset.py
@@ -31,9 +31,12 @@ class ScantxoutsetTest(BitcoinTestFramework):
pubk2 = self.nodes[0].getaddressinfo(addr_LEGACY)['pubkey']
addr_BECH32 = self.nodes[0].getnewaddress("", "bech32")
pubk3 = self.nodes[0].getaddressinfo(addr_BECH32)['pubkey']
- self.nodes[0].sendtoaddress(addr_P2SH_SEGWIT, 0.001)
- self.nodes[0].sendtoaddress(addr_LEGACY, 0.002)
- self.nodes[0].sendtoaddress(addr_BECH32, 0.004)
+ txid = self.nodes[0].sendtoaddress(addr_P2SH_SEGWIT, 0.001)
+ self.nodes[0].lockunspent(unlock=False, transactions=[{"txid": txid, "vout": 0}, {"txid": txid, "vout": 1}])
+ txid = self.nodes[0].sendtoaddress(addr_LEGACY, 0.002)
+ self.nodes[0].lockunspent(unlock=False, transactions=[{"txid": txid, "vout": 0}, {"txid": txid, "vout": 1}])
+ txid = self.nodes[0].sendtoaddress(addr_BECH32, 0.004)
+ self.nodes[0].lockunspent(unlock=False, transactions=[{"txid": txid, "vout": 0}, {"txid": txid, "vout": 1}])
#send to child keys of tprv8ZgxMBicQKsPd7Uf69XL1XwhmjHopUGep8GuEiJDZmbQz6o58LninorQAfcKZWARbtRtfnLcJ5MQ2AtHcQJCCRUcMRvmDUjyEmNUWwx8UbK
self.nodes[0].sendtoaddress("mkHV1C6JLheLoUSSZYk7x3FH5tnx9bu7yc", 0.008) # (m/0'/0'/0')