Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Sebastian Schrader
Kea
Commits
f5811cdf
Commit
f5811cdf
authored
Oct 01, 2012
by
Tomek Mrugalski
🛰
Browse files
[master] Test fix for ambiguous IPv6 notation (ending with :0 vs ::)
parent
723885f4
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/lib/dhcp/tests/addr_utilities_unittest.cc
View file @
f5811cdf
...
...
@@ -64,15 +64,15 @@ TEST(Pool6Test, lastAddrInPrefix) {
}
TEST
(
Pool6Test
,
firstAddrInPrefix
)
{
IOAddress
addr1
(
"2001:db8:1:1234:5678:
abcd:1234
:beef"
);
IOAddress
addr1
(
"2001:db8:1:1234:5678:
1234:abcd
:beef"
);
// Prefixes rounded to nibbles are easy...
EXPECT_EQ
(
"2001:db8:1:1234:5678:
abcd:
1234:
0
"
,
firstAddrInPrefix
(
addr1
,
112
).
toText
());
EXPECT_EQ
(
"2001:db8:1:1234:5678:
abcd:
1230:
0
"
,
firstAddrInPrefix
(
addr1
,
108
).
toText
());
EXPECT_EQ
(
"2001:db8:1:1234:5678:
abcd:
1200:
0
"
,
firstAddrInPrefix
(
addr1
,
104
).
toText
());
EXPECT_EQ
(
"2001:db8:1:1234:5678:1234:
:
"
,
firstAddrInPrefix
(
addr1
,
96
).
toText
());
EXPECT_EQ
(
"2001:db8:1:1234:5678:1230:
:
"
,
firstAddrInPrefix
(
addr1
,
92
).
toText
());
EXPECT_EQ
(
"2001:db8:1:1234:5678:1200:
:
"
,
firstAddrInPrefix
(
addr1
,
88
).
toText
());
EXPECT_EQ
(
"2001:db8:1:1234::"
,
firstAddrInPrefix
(
addr1
,
64
).
toText
());
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment