"""
# Check if the IP is the gateway
if ip_address == gateway_ip:
- return True
+ # Gateway is not in allocation pool
+ return False
# Check if the requested IP is in a defined allocation pool
pool_qry = context.session.query(models_v2.IPAllocationPool)
allocation_pools=allocation_pools)
def test_subnet_with_allocation_range(self):
+ cfg.CONF.set_override('dhcp_lease_duration', 0)
fmt = 'json'
with self.network() as network:
net_id = network['network']['id']
port_id = port['port']['id']
# delete the port
self._delete('ports', port['port']['id'])
+ cfg.CONF.set_override('dhcp_lease_duration', 120)
def test_create_subnet_with_none_gateway_allocation_pool(self):
cidr = '10.0.0.0/24'