From eeaaa58d2ccc243a7506d34bca47c678867d6dd5 Mon Sep 17 00:00:00 2001 From: Sebastian Falbesoner Date: Sat, 25 Apr 2020 13:44:44 +0200 Subject: test: replace inv type magic numbers by constants --- test/functional/p2p_fingerprint.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'test/functional/p2p_fingerprint.py') diff --git a/test/functional/p2p_fingerprint.py b/test/functional/p2p_fingerprint.py index c9fbb830c8..d743abe681 100755 --- a/test/functional/p2p_fingerprint.py +++ b/test/functional/p2p_fingerprint.py @@ -11,7 +11,7 @@ the node should pretend that it does not have it to avoid fingerprinting. import time from test_framework.blocktools import (create_block, create_coinbase) -from test_framework.messages import CInv +from test_framework.messages import CInv, MSG_BLOCK from test_framework.mininode import ( P2PInterface, msg_headers, @@ -48,7 +48,7 @@ class P2PFingerprintTest(BitcoinTestFramework): # Send a getdata request for a given block hash def send_block_request(self, block_hash, node): msg = msg_getdata() - msg.inv.append(CInv(2, block_hash)) # 2 == "Block" + msg.inv.append(CInv(MSG_BLOCK, block_hash)) node.send_message(msg) # Send a getheaders request for a given single block hash -- cgit v1.2.3