mirror of
https://gitlab.isc.org/isc-projects/kea
synced 2025-08-30 21:45:37 +00:00
[master] Fixed 4o6subnetInterfaceId for not 64 bit machines (from hackathon94)
This commit is contained in:
@@ -4014,13 +4014,9 @@ TEST_F(Dhcp4ParserTest, 4o6subnetInterfaceId) {
|
|||||||
ASSERT_TRUE(ifaceid);
|
ASSERT_TRUE(ifaceid);
|
||||||
|
|
||||||
vector<uint8_t> data = ifaceid->getData();
|
vector<uint8_t> data = ifaceid->getData();
|
||||||
const char *exp_data = "vlan123";
|
EXPECT_EQ(7, data.size());
|
||||||
// Let's convert vlan123 to vector<uint8_t> format.
|
const char *exp = "vlan123";
|
||||||
// We need to skip the last \0 byte, thuse sizeof() - 1.
|
EXPECT_EQ(0, memcmp(&data[0], exp, data.size()));
|
||||||
vector<uint8_t> exp(exp_data, exp_data + sizeof(exp_data) - 1);
|
|
||||||
|
|
||||||
EXPECT_TRUE(exp == data);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user