aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMartin Zumsande <mzumsande@gmail.com>2022-10-27 17:56:58 -0400
committerMartin Zumsande <mzumsande@gmail.com>2022-10-28 10:17:50 -0400
commit8a9f1e4d18e2b94509548af2aa3ad14185793f73 (patch)
treec97ed98eec6d8c1d4e67ed91c003b2cf2b2fcc0e /test
parent551c8e9526d2502f857e1ef6348c7f1380f37443 (diff)
downloadbitcoin-8a9f1e4d18e2b94509548af2aa3ad14185793f73.tar.xz
test: fix intermittent failure in rpc_getblockfrompeer.py
by adding a sync to make sure the node has received the header before we query it for the block
Diffstat (limited to 'test')
-rwxr-xr-xtest/functional/rpc_getblockfrompeer.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/functional/rpc_getblockfrompeer.py b/test/functional/rpc_getblockfrompeer.py
index fd4d1992eb..8bd3366e36 100755
--- a/test/functional/rpc_getblockfrompeer.py
+++ b/test/functional/rpc_getblockfrompeer.py
@@ -100,7 +100,7 @@ class GetBlockFromPeerTest(BitcoinTestFramework):
# Connect a P2PInterface to the pruning node and have it submit only the header of the
# block that the pruning node has not seen
node1_interface = self.nodes[1].add_p2p_connection(P2PInterface())
- node1_interface.send_message(msg_headers([block]))
+ node1_interface.send_and_ping(msg_headers([block]))
# Get the peer id of the P2PInterface from the pruning node
node1_peers = self.nodes[1].getpeerinfo()