diff options
author | MarcoFalke <falke.marco@gmail.com> | 2017-08-16 18:17:34 +0200 |
---|---|---|
committer | MarcoFalke <falke.marco@gmail.com> | 2017-10-03 18:29:48 +0200 |
commit | 5398f205e3ba1f7542deeba420f9e198bcb635f5 (patch) | |
tree | c6192e754c839184b61de07d113924ef1cf8acf3 /test/functional/example_test.py | |
parent | 1d80d1e319b41e5187d5949b3c22c35df182ba3c (diff) |
qa: Move wait_until to util
Github-Pull: #11068
Rebased-From: 08ce33f8e95efa81b37ddc6b3350462c61bbfd51
Diffstat (limited to 'test/functional/example_test.py')
-rwxr-xr-x | test/functional/example_test.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/functional/example_test.py b/test/functional/example_test.py index 7709524f23..a54b5278e4 100755 --- a/test/functional/example_test.py +++ b/test/functional/example_test.py @@ -23,13 +23,13 @@ from test_framework.mininode import ( mininode_lock, msg_block, msg_getdata, - wait_until, ) from test_framework.test_framework import BitcoinTestFramework from test_framework.util import ( assert_equal, connect_nodes, p2p_port, + wait_until, ) # NodeConnCB is a class containing callbacks to be executed when a P2P @@ -209,7 +209,7 @@ class ExampleTest(BitcoinTestFramework): # wait_until() will loop until a predicate condition is met. Use it to test properties of the # NodeConnCB objects. - assert wait_until(lambda: sorted(blocks) == sorted(list(node2.block_receive_map.keys())), timeout=5) + wait_until(lambda: sorted(blocks) == sorted(list(node2.block_receive_map.keys())), timeout=5, lock=mininode_lock) self.log.info("Check that each block was received only once") # The network thread uses a global lock on data access to the NodeConn objects when sending and receiving |