mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-04-02 08:59:08 +02:00
test: enable v2 transport for p2p_node_network_limited.py
This commit is contained in:
parent
3598a1b5c9
commit
cc961c2695
@ -8,7 +8,15 @@ Tests that a node configured with -prune=550 signals NODE_NETWORK_LIMITED correc
|
||||
and that it responds to getdata requests for blocks correctly:
|
||||
- send a block within 288 + 2 of the tip
|
||||
- disconnect peers who request blocks older than that."""
|
||||
from test_framework.messages import CInv, MSG_BLOCK, msg_getdata, msg_verack, NODE_NETWORK_LIMITED, NODE_WITNESS
|
||||
from test_framework.messages import (
|
||||
CInv,
|
||||
MSG_BLOCK,
|
||||
NODE_NETWORK_LIMITED,
|
||||
NODE_P2P_V2,
|
||||
NODE_WITNESS,
|
||||
msg_getdata,
|
||||
msg_verack,
|
||||
)
|
||||
from test_framework.p2p import P2PInterface
|
||||
from test_framework.test_framework import BitcoinTestFramework
|
||||
from test_framework.util import (
|
||||
@ -50,6 +58,8 @@ class NodeNetworkLimitedTest(BitcoinTestFramework):
|
||||
node = self.nodes[0].add_p2p_connection(P2PIgnoreInv())
|
||||
|
||||
expected_services = NODE_WITNESS | NODE_NETWORK_LIMITED
|
||||
if self.options.v2transport:
|
||||
expected_services |= NODE_P2P_V2
|
||||
|
||||
self.log.info("Check that node has signalled expected services.")
|
||||
assert_equal(node.nServices, expected_services)
|
||||
|
@ -365,6 +365,7 @@ BASE_SCRIPTS = [
|
||||
'wallet_orphanedreward.py',
|
||||
'wallet_timelock.py',
|
||||
'p2p_node_network_limited.py',
|
||||
'p2p_node_network_limited.py --v2transport',
|
||||
'p2p_permissions.py',
|
||||
'feature_blocksdir.py',
|
||||
'wallet_startup.py',
|
||||
|
Loading…
x
Reference in New Issue
Block a user