Fix OVN test_agents running on devstack environments

test_kill_ovn_controller should be skipped on devstack because the
ovn-controller process is not started automatically

test_restart_ovn_controller was using docker because the ovn-controller
service name was wrong

Change-Id: Ia3f70a23f676fbbc2b3d129df1fac77bdadfcd29
This commit is contained in:
Eduardo Olivares 2021-01-29 12:22:15 +01:00
parent 259c5246b3
commit bc06c338f3
2 changed files with 4 additions and 1 deletions

View File

@ -185,7 +185,7 @@ class OpenStackTopology(tobiko.SharedFixture):
neutron.OPENVSWITCH_AGENT: 'devstack@q-agt',
neutron.METADATA_AGENT: 'devstack@q-meta',
neutron.OVN_METADATA_AGENT: 'devstack@q-ovn-metadata-agent',
neutron.OVN_CONTROLLER: 'devstack@ovn-controller'
neutron.OVN_CONTROLLER: 'ovn-controller'
}
agent_to_container_name_mappings: typing.Dict[str, str] = {}

View File

@ -584,6 +584,9 @@ class OvnControllerTest(BaseAgentTest):
self.container_name = self.get_agent_container_name(
self.agent_name)
if not self.container_name:
self.skipTest(f"Missing container(s): '{self.container_name}'")
for host in hosts:
ssh_client = topology.get_openstack_node(hostname=host).ssh_client
pid = None