Skip to content

Commit

Permalink
QA: p2p_addrv2_relay: Be flexible with the order of addr processing
Browse files Browse the repository at this point in the history
Github-Pull: bitcoin#22387
Partially-Rebased-From: 5648138
  • Loading branch information
sipa authored and luke-jr committed Dec 15, 2021
1 parent b639380 commit 2af73be
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/functional/p2p_addrv2_relay.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ def __init__(self):
super().__init__(support_addrv2 = True)

def on_addrv2(self, message):
if ADDRS == message.addrs:
expected_set = set((addr.ip, addr.port) for addr in ADDRS)
received_set = set((addr.ip, addr.port) for addr in message.addrs)
if expected_set == received_set:
self.addrv2_received_and_checked = True

def wait_for_addrv2(self):
Expand Down

0 comments on commit 2af73be

Please sign in to comment.