diff options
author | Wladimir J. van der Laan <laanwj@protonmail.com> | 2020-05-06 15:13:42 +0200 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@protonmail.com> | 2020-05-06 15:30:31 +0200 |
commit | 7bcc42b4035b878719d13201286e322989b415c5 (patch) | |
tree | 9e669b92516612f3bee6056ce305259c569a870c /test/functional/feature_loadblock.py | |
parent | c6b15ec0ee4679a22abefb0d8d528f026acd8b67 (diff) | |
parent | fa3f9a05660687bf4146e089050e944a1d6cbe3c (diff) | |
download | bitcoin-7bcc42b4035b878719d13201286e322989b415c5.tar.xz |
Merge #18873: test: Fix intermittent sync_blocks failures
fa3f9a05660687bf4146e089050e944a1d6cbe3c test: Fix intermittent sync_blocks failures (MarcoFalke)
Pull request description:
Fixes #18872
Fixes #18737
Fixes #18801
See docstring for motivation and description
ACKs for top commit:
laanwj:
Code review ACK fa3f9a05660687bf4146e089050e944a1d6cbe3c
Tree-SHA512: acd52d386a6849f7ff1cb1a51a439dc3c76e0e3a4dd8d22030df0ebb09b44497c61c56331ff65724b695d82d86b0ebb24608f9e637008e5dacb7676b0c448889
Diffstat (limited to 'test/functional/feature_loadblock.py')
-rwxr-xr-x | test/functional/feature_loadblock.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/test/functional/feature_loadblock.py b/test/functional/feature_loadblock.py index 1138b0f0ea..82f1331685 100755 --- a/test/functional/feature_loadblock.py +++ b/test/functional/feature_loadblock.py @@ -16,10 +16,8 @@ import sys import tempfile import urllib -from test_framework.test_framework import ( - BitcoinTestFramework, -) -from test_framework.util import assert_equal, wait_until +from test_framework.test_framework import BitcoinTestFramework +from test_framework.util import assert_equal class LoadblockTest(BitcoinTestFramework): @@ -75,7 +73,7 @@ class LoadblockTest(BitcoinTestFramework): self.log.info("Restart second, unsynced node with bootstrap file") self.stop_node(1) self.start_node(1, ["-loadblock=" + bootstrap_file]) - wait_until(lambda: self.nodes[1].getblockcount() == 100) + assert_equal(self.nodes[1].getblockcount(), 100) # start_node is blocking on all block files being imported assert_equal(self.nodes[1].getblockchaininfo()['blocks'], 100) assert_equal(self.nodes[0].getbestblockhash(), self.nodes[1].getbestblockhash()) |