Add more exhaustive tests for various IPv6 address notations
This commit is contained in:
parent
a89412ecb1
commit
838e71edb7
1 changed files with 14 additions and 0 deletions
|
@ -17,6 +17,20 @@ class TestParseAddress(unittest.TestCase):
|
|||
'[::1]:442': ['::1', 442],
|
||||
'abcd:ef98:7654:3210:abcd:ef98:7654:3210': ['abcd:ef98:7654:3210:abcd:ef98:7654:3210', None],
|
||||
'[abcd:ef98:7654:3210:abcd:ef98:7654:3210]:42': ['abcd:ef98:7654:3210:abcd:ef98:7654:3210', 42],
|
||||
'1234:5678:9abc:def0:1234:5678:9abc:def0': ['1234:5678:9abc:def0:1234:5678:9abc:def0', None],
|
||||
'1234::9abc:def0:1234:5678:9abc:def0': ['1234::9abc:def0:1234:5678:9abc:def0', None],
|
||||
'1234:5678::def0:1234:5678:9abc:def0': ['1234:5678::def0:1234:5678:9abc:def0', None],
|
||||
'1234:5678:9abc::1234:5678:9abc:def0': ['1234:5678:9abc::1234:5678:9abc:def0', None],
|
||||
'1234:5678:9abc:def0::5678:9abc:def0': ['1234:5678:9abc:def0::5678:9abc:def0', None],
|
||||
'1234:5678:9abc:def0:1234::9abc:def0': ['1234:5678:9abc:def0:1234::9abc:def0', None],
|
||||
'1234:5678:9abc:def0:1234:5678::def0': ['1234:5678:9abc:def0:1234:5678::def0', None],
|
||||
'1234:5678:9abc:def0:1234:5678::': ['1234:5678:9abc:def0:1234:5678::', None],
|
||||
'::9abc:def0:1234:5678:9abc:def0': ['::9abc:def0:1234:5678:9abc:def0', None],
|
||||
'0:0:0:0:0:ffff:1.2.3.4': ['0:0:0:0:0:ffff:1.2.3.4', None],
|
||||
'0:0:0:0:0:0:1.2.3.4': ['0:0:0:0:0:0:1.2.3.4', None],
|
||||
'::ffff:1.2.3.4': ['::ffff:1.2.3.4', None],
|
||||
'::1.2.3.4': ['::1.2.3.4', None],
|
||||
'1234::': ['1234::', None],
|
||||
|
||||
# Hostnames
|
||||
'some-host': ['some-host', None],
|
||||
|
|
Loading…
Reference in a new issue