Skip to content

Commit aa36213

Browse files
committed
test: use CInv::MSG_WITNESS_TX flag in p2p_segwit
1 parent 24ee4f0 commit aa36213

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

test/functional/p2p_segwit.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
MSG_BLOCK,
2626
MSG_TX,
2727
MSG_WITNESS_FLAG,
28+
MSG_WITNESS_TX,
2829
MSG_WTX,
2930
NODE_NETWORK,
3031
NODE_WITNESS,
@@ -2158,7 +2159,7 @@ def received_wtxidrelay():
21582159
self.wtx_node.wait_for_getdata([tx.sha256], 60)
21592160
with mininode_lock:
21602161
lgd = self.wtx_node.lastgetdata[:]
2161-
assert_equal(lgd, [CInv(MSG_TX|MSG_WITNESS_FLAG, tx.sha256)])
2162+
assert_equal(lgd, [CInv(MSG_WITNESS_TX, tx.sha256)])
21622163

21632164
# Send tx through
21642165
test_transaction_acceptance(self.nodes[0], self.wtx_node, tx, with_witness=False, accepted=True)

test/functional/test_framework/messages.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@
6363
MSG_WTX = 5
6464
MSG_WITNESS_FLAG = 1 << 30
6565
MSG_TYPE_MASK = 0xffffffff >> 2
66+
MSG_WITNESS_TX = MSG_TX | MSG_WITNESS_FLAG
6667

6768
FILTER_TYPE_BASIC = 0
6869

0 commit comments

Comments
 (0)