[tests] add ipv6 source selection test (#4380)

This commit is contained in:
Rongli Sun
2019-12-06 08:51:23 -08:00
committed by Jonathan Hui
parent bf4dae0c18
commit 76f847babc
4 changed files with 186 additions and 2 deletions
+6
View File
@@ -353,6 +353,12 @@ class Message(object):
== ipaddress.ip_address(ipv6_address)
)
def assertSentFromSourceAddress(self, ipv6_address):
assert (
self.ipv6_packet.ipv6_header.source_address
== ipaddress.ip_address(ipv6_address)
)
def assertSentWithHopLimit(self, hop_limit):
assert self.ipv6_packet.ipv6_header.hop_limit == hop_limit