diff --git a/whitebox_neutron_tempest_plugin/tests/scenario/base.py b/whitebox_neutron_tempest_plugin/tests/scenario/base.py index 72ff8ad..faf3968 100644 --- a/whitebox_neutron_tempest_plugin/tests/scenario/base.py +++ b/whitebox_neutron_tempest_plugin/tests/scenario/base.py @@ -1028,6 +1028,7 @@ class TrafficFlowTest(BaseTempestWhiteboxTestCase): node['is_networker']): LOG.debug('Traffic is not captured on node %s because it is ' 'not: controller, compute, networker', node['name']) + continue elif (WB_CONF.openstack_type == 'podified' and node['is_controller']): capture_client = self.proxy_host_client @@ -1049,7 +1050,8 @@ class TrafficFlowTest(BaseTempestWhiteboxTestCase): def _stop_captures(self): for node in self.nodes: - node['capture'].stop() + if node.get('capture'): + node['capture'].stop() def check_east_west_icmp_flow( self, dst_ip, expected_routing_nodes, expected_macs, ssh_client): @@ -1090,7 +1092,8 @@ class TrafficFlowTest(BaseTempestWhiteboxTestCase): ','.join(expected_routing_nodes))) actual_routing_nodes = [node['name'] for node in self.nodes if - not node['capture'].is_empty()] + (node.get('capture') and + not node['capture'].is_empty())] LOG.debug('Actual routing nodes: {}'.format( ','.join(actual_routing_nodes))) self.assertCountEqual(expected_routing_nodes, actual_routing_nodes) @@ -1143,7 +1146,8 @@ class TrafficFlowTest(BaseTempestWhiteboxTestCase): LOG.debug('Expected routing nodes: {}'.format(expected_routing_nodes)) actual_routing_nodes = [node['name'] for node in self.nodes if - not node['capture'].is_empty()] + (node.get('capture') and + not node['capture'].is_empty())] LOG.debug('Actual routing nodes: {}'.format( ','.join(actual_routing_nodes))) self.assertCountEqual(expected_routing_nodes, actual_routing_nodes)