Be specific about a FIP to be checked in CP tests
The configure step for the DRAgent tests configures a name for a floating IP to be checked for at the peer side. Since the data plane tests add one as well for an instance, make sure the control plane-only tests rely on the FIP that has a specific name. This can be useful if the tests are run in a different order.
This commit is contained in:
@@ -26,6 +26,7 @@ from zaza.openstack.utilities import (
|
||||
cli as cli_utils,
|
||||
juju as juju_utils,
|
||||
)
|
||||
from zaza.openstack.configure.bgp_speaker import NDR_TEST_FIP
|
||||
|
||||
|
||||
class DRAgentTest(neutron_tests.NeutronNetworkingBase):
|
||||
@@ -83,7 +84,7 @@ class DRAgentTest(neutron_tests.NeutronNetworkingBase):
|
||||
# Get expected advertised routes
|
||||
private_cidr = self.project_subnet['cidr']
|
||||
floating_ip_cidr = "{}/32".format(
|
||||
self.neutron_client.list_floatingips()
|
||||
self.neutron_client.list_floatingips(name=NDR_TEST_FIP)
|
||||
["floatingips"][0]["floating_ip_address"])
|
||||
|
||||
# This test may run immediately after configuration.
|
||||
|
||||
@@ -26,7 +26,7 @@ from zaza.openstack.utilities import (
|
||||
)
|
||||
|
||||
|
||||
FIP_TEST = "FIP TEST"
|
||||
NDR_TEST_FIP = "NDR_TEST_FIP"
|
||||
|
||||
|
||||
def setup_bgp_speaker(peer_application_name, keystone_session=None):
|
||||
@@ -90,7 +90,8 @@ def setup_bgp_speaker(peer_application_name, keystone_session=None):
|
||||
# Create Floating IP to advertise
|
||||
logging.info("Creating floating IP to advertise")
|
||||
port = openstack_utils.create_port(neutron_client,
|
||||
FIP_TEST, openstack_utils.PRIVATE_NET)
|
||||
NDR_TEST_FIP,
|
||||
openstack_utils.PRIVATE_NET)
|
||||
floating_ip = openstack_utils.create_floating_ip(neutron_client,
|
||||
openstack_utils.EXT_NET,
|
||||
port=port)
|
||||
|
||||
Reference in New Issue
Block a user