Merge "Tempest nsxv cases fix"

This commit is contained in:
Zuul 2020-04-03 10:21:01 +00:00 committed by Gerrit Code Review
commit d5c4d014ad
2 changed files with 10 additions and 16 deletions

View File

@ -62,12 +62,7 @@ class MultipleAllowAddress(feature_manager.FeatureManager):
manager_ip, CONF.nsxv.user, CONF.nsxv.password)
def _assign_ip_address(self, ssh_source, interface_name, ip_address):
int_face = interface_name.split('.')[0]
vlan_id = interface_name.split('.')[1]
ssh_source.exec_command("sudo ip link add link %s name %s type vlan\
id %s" % (int_face, interface_name, vlan_id))
ssh_source.exec_command("sudo ifconfig %s %s/24 \
ssh_source.exec_command("sudo /sbin/ifconfig %s %s netmask 255.255.255.0 \
up" % (interface_name, ip_address))
def verify_ping_to_fip_from_ext_vm(self, server_details):
@ -657,8 +652,8 @@ class MultipleAllowAddress(feature_manager.FeatureManager):
vm2_ip_address = vm2['floating_ips'][0]['floating_ip_address']
ssh_source2 = self._get_remote_client(vm2_ip_address,
use_password=True)
self._assign_ip_address(ssh_source1, 'eth0.1', vm1_ip)
self._assign_ip_address(ssh_source2, 'eth0.1', vm2_ip)
self._assign_ip_address(ssh_source1, 'eth0:1', vm1_ip)
self._assign_ip_address(ssh_source2, 'eth0:1', vm2_ip)
# Verify Connectivity between vms
self.check_remote_connectivity(ssh_source1, vm2_ip,
should_succeed=True)

View File

@ -139,11 +139,10 @@ class TestNewCase(feature_manager.FeatureManager):
network_state2 = self.create_topology_network(network_name2)
subnet_state1 = self.create_topology_subnet(
subnet_name1, network_state1, router_id=router_state["id"])
subnet_state2 = self.create_topology_subnet(subnet_name2,
network_state2,
router_id=router_state2["\
id"],
cidr=constants.CIDR)
subnet_st2 = self.create_topology_subnet(subnet_name2,
network_state2,
router_id=router_state2["id"],
cidr=constants.CIDR)
if create_instance:
self.create_topology_instance("server1",
[network_state1])
@ -154,7 +153,7 @@ class TestNewCase(feature_manager.FeatureManager):
network_state1=network_state1,
network_state2=network_state2,
subnet_state1=subnet_state1,
subnet_state2=subnet_state2)
subnet_state2=subnet_st2)
return topology_dict
def create_topo_across_networks(self, namestart, create_instance=True):
@ -899,7 +898,7 @@ class TestNewCase(feature_manager.FeatureManager):
clients=self.cmgr_adm)
ip_address = vm1['floating_ips'][0]['floating_ip_address']
ssh_source = self._get_remote_client(ip_address, use_password=True)
remote_ip = vm2.values()[1].values()[0][0]['addr']
remote_ip = sorted(vm2['addresses'].values())[0][0]['addr']
# Verify connectivity between vms
self.check_remote_connectivity(ssh_source, remote_ip,
should_succeed=True)
@ -946,7 +945,7 @@ class TestNewCase(feature_manager.FeatureManager):
clients=self.cmgr_adm)
ip_address = vm1['floating_ips'][0]['floating_ip_address']
ssh_source = self._get_remote_client(ip_address, use_password=True)
remote_ip = vm2.values()[1].values()[0][0]['addr']
remote_ip = sorted(vm2['addresses'].values())[0][0]['addr']
# Verify Connectivity between vms
self.check_remote_connectivity(ssh_source, remote_ip,
should_succeed=True)