diff options
author | Martin Zumsande <mzumsande@gmail.com> | 2024-02-12 15:27:15 -0500 |
---|---|---|
committer | Martin Zumsande <mzumsande@gmail.com> | 2024-02-12 15:27:18 -0500 |
commit | 44d11532f80705b790bc6e28df9a96ac54b25f9b (patch) | |
tree | 8f8a2b4ed4619f23db88297c61aa8407a1b4fe7d /test/functional/wallet_reorgsrestore.py | |
parent | 60ac503800bb38db97f1cee786d1be38996e614f (diff) | |
download | bitcoin-44d11532f80705b790bc6e28df9a96ac54b25f9b.tar.xz |
test: fix intermittent failure in wallet_reorgrestore.py
...by adding a missing sync_blocks call.
There was a race at node2 between connecting the block
produced by node 0, and using -generate to create new blocks
itself. In the failed run, the latter happened first,
resulting in a final block height that was smaller by 1 than
expected.
Diffstat (limited to 'test/functional/wallet_reorgsrestore.py')
-rwxr-xr-x | test/functional/wallet_reorgsrestore.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/test/functional/wallet_reorgsrestore.py b/test/functional/wallet_reorgsrestore.py index 86a2905c72..4271f3e481 100755 --- a/test/functional/wallet_reorgsrestore.py +++ b/test/functional/wallet_reorgsrestore.py @@ -45,6 +45,7 @@ class ReorgsRestoreTest(BitcoinTestFramework): txid = self.nodes[0].sendtoaddress(self.nodes[0].getnewaddress(), Decimal("10")) tx = self.nodes[0].gettransaction(txid) self.generate(self.nodes[0], 4, sync_fun=self.no_op) + self.sync_blocks([self.nodes[0], self.nodes[2]]) tx_before_reorg = self.nodes[0].gettransaction(txid) assert_equal(tx_before_reorg["confirmations"], 4) |