ElementPtr json = Element::fromJSON(config);
- EXPECT_NO_THROW(x = configureDhcp4Server(*srv_, json));
- ASSERT_TRUE(x);
- comment_ = parseAnswer(rcode_, x);
- ASSERT_EQ(0, rcode_);
-
int cnt = 0; // Number of reconfigurations
do {
- ElementPtr json = Element::fromJSON(config);
-
EXPECT_NO_THROW(x = configureDhcp4Server(*srv_, json));
ASSERT_TRUE(x);
comment_ = parseAnswer(rcode_, x);
ElementPtr json = Element::fromJSON(config);
- EXPECT_NO_THROW(x = configureDhcp4Server(*srv_, json));
- ASSERT_TRUE(x);
- comment_ = parseAnswer(rcode_, x);
- ASSERT_EQ(0, rcode_);
-
int cnt = 0; // Number of reconfigurations
-
do {
- ElementPtr json = Element::fromJSON(config);
-
EXPECT_NO_THROW(x = configureDhcp4Server(*srv_, json));
ASSERT_TRUE(x);
comment_ = parseAnswer(rcode_, x);
// Repeat reconfiguration process 10 times and check that the subnet-id
// is set to the same value.
- } while (++cnt < 10);
+ } while (++cnt < 3);
}
// Check that the configuration with two subnets having the same id is rejected.
int cnt = 0; // Number of reconfigurations
- do {
- ElementPtr json = Element::fromJSON(config);
+ ElementPtr json = Element::fromJSON(config);
+ do {
EXPECT_NO_THROW(x = configureDhcp6Server(srv_, json));
ASSERT_TRUE(x);
comment_ = parseAnswer(rcode_, x);
int cnt = 0; // Number of reconfigurations
- do {
- ElementPtr json = Element::fromJSON(config);
+ ElementPtr json = Element::fromJSON(config);
+ do {
EXPECT_NO_THROW(x = configureDhcp6Server(srv_, json));
ASSERT_TRUE(x);
comment_ = parseAnswer(rcode_, x);
// Repeat reconfiguration process 10 times and check that the subnet-id
// is set to the same value.
- } while (++cnt < 10);
+ } while (++cnt < 3);
}
// CHeck that the configuration with two subnets having the same id is rejected.
/// CASE 2: Configure 4 subnets, then reconfigure and remove one
/// from in between (not first, not last)
- /// @todo: Uncomment subnet removal test as part of #3281.
json = Element::fromJSON(config4);
EXPECT_NO_THROW(x = configureDhcp6Server(srv_, json));
ASSERT_TRUE(x);
/// @todo: Check that there is no subnet with the same interface-id
if (isDuplicate(*subnet)) {
isc_throw(isc::dhcp::DuplicateSubnetID, "ID of the new IPv6 subnet '"
- << subnet->getID() << "' is the same as ID of an existing"
- " subnet");
+ << subnet->getID() << "' is already in use");
}
LOG_DEBUG(dhcpsrv_logger, DHCPSRV_DBG_TRACE, DHCPSRV_CFGMGR_ADD_SUBNET6)
.arg(subnet->toText());
/// other already defined subnet.
if (isDuplicate(*subnet)) {
isc_throw(isc::dhcp::DuplicateSubnetID, "ID of the new IPv4 subnet '"
- << subnet->getID() << "' is the same as ID of an existing"
- " subnet");
+ << subnet->getID() << "' is already in use");
}
LOG_DEBUG(dhcpsrv_logger, DHCPSRV_DBG_TRACE, DHCPSRV_CFGMGR_ADD_SUBNET4)
.arg(subnet->toText());
EXPECT_NE(id0, id1);
// Create third subnet but this time select an arbitrary id. The id
- // we use us the one of second subnet. That way we ensure that the
+ // we use the one of the second subnet. That way we ensure that the
// subnet id we provide via constructor is used and it is not
// autogenerated - if it was autogenerated we would get id other
// than id1 because id1 has already been used.