aboutsummaryrefslogtreecommitdiff
path: root/test/functional/rpc_net.py
diff options
context:
space:
mode:
authorJon Atack <jon@atack.com>2021-02-01 23:56:20 +0100
committerJon Atack <jon@atack.com>2021-02-02 00:16:04 +0100
commit0dbde700a6e9894a8ead20f2eebd0ff6554ef2d9 (patch)
treea3b1dcd90449da31658189b8f3d1ffc56ab176f4 /test/functional/rpc_net.py
parent1c3af37881adbbc37fb9924bcf69c403fcae1ae7 (diff)
downloadbitcoin-0dbde700a6e9894a8ead20f2eebd0ff6554ef2d9.tar.xz
rpc: use GetNetworkNames() in getnetworkinfo and getpeerinfo helps
Diffstat (limited to 'test/functional/rpc_net.py')
-rwxr-xr-xtest/functional/rpc_net.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/functional/rpc_net.py b/test/functional/rpc_net.py
index de0b7f303f..f1cb7c82bd 100755
--- a/test/functional/rpc_net.py
+++ b/test/functional/rpc_net.py
@@ -101,6 +101,9 @@ class NetTest(BitcoinTestFramework):
assert_equal(peer_info[1][0]['connection_type'], 'manual')
assert_equal(peer_info[1][1]['connection_type'], 'inbound')
+ # Check dynamically generated networks list in getpeerinfo help output.
+ assert "(ipv4, ipv6, onion, not_publicly_routable)" in self.nodes[0].help("getpeerinfo")
+
def test_getnettotals(self):
self.log.info("Test getnettotals")
# Test getnettotals and getpeerinfo by doing a ping. The bytes
@@ -149,6 +152,9 @@ class NetTest(BitcoinTestFramework):
for info in network_info:
assert_net_servicesnames(int(info["localservices"], 0x10), info["localservicesnames"])
+ # Check dynamically generated networks list in getnetworkinfo help output.
+ assert "(ipv4, ipv6, onion)" in self.nodes[0].help("getnetworkinfo")
+
def test_getaddednodeinfo(self):
self.log.info("Test getaddednodeinfo")
assert_equal(self.nodes[0].getaddednodeinfo(), [])