Check the number of neutron ports after controller restart

When port pool enabled, after restart of kuryr controller
the number of neutron ports should be the same

Change-Id: Ic6905d2f57a4f37cd70618c416ff37446bbef746
This commit is contained in:
Genadi Chereshnya 2018-11-18 16:33:04 +02:00
parent 26e363f0cb
commit e5c84c765c
1 changed files with 8 additions and 0 deletions

View File

@ -72,6 +72,14 @@ class TestPortPoolScenario(base.BaseKuryrScenarioTest):
# kuryr-controller
self.restart_kuryr_controller()
port_list_num_after_restart = len(
self.os_admin.ports_client.list_ports(
fixed_ips='subnet_id=%s' % subnet_id)['ports'])
self.assertEqual(updated_port_list_num, port_list_num_after_restart,
"Number of Neutron ports on namespace %s subnet "
"changed after kuryr-controller "
"restart" % namespace_name)
# create additional pod
pod_name3, _ = self.create_pod(namespace=namespace_name)