Skip to content

Commit 2b611b7

Browse files
committed
[Fullstack] Drop all linuxbridge scenarios from fullstack tests
As we discussed on the Neutron CI meeting on 7.11.2023 (it was video meeting, no strict logs stored) [1], to save some time in the fullstack job execution we want to stop running all the Linuxbridge related tests/scenarios in fullstack test suite. Linuxbridge is experimental feature now, not really fully supported by the Neutron team so we are allowed to do so in this case. This patch is doing exactly that. There are no any Linuxbridge agent related tests/scenarios. Support for Linuxbridge in the Fullstack framework wasn't however removed completely. It is like that because of 2 reasons: * there is one DHCP agent related test which tests different segments and is using Linuxbridge agent on one of the fake nodes, * maybe there will be at some point need to have some Linuxbridge agent test there so the infrastructure for that is still available, it won't cause any issues while it's (almost) not used currently. [1] https://meetings.opendev.org/meetings/neutron_ci/2023/neutron_ci.2023-11-07-15.00.html Change-Id: I709c477f66ada037e47ec9abc7fbed1d1a238d20 (cherry picked from commit 688c5e2)
1 parent a680d58 commit 2b611b7

File tree

8 files changed

+3
-117
lines changed

8 files changed

+3
-117
lines changed

neutron/tests/fullstack/test_agent_bandwidth_report.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ class TestPlacementBandwidthReport(base.BaseFullStackTestCase):
188188
scenarios = [
189189
(constants.AGENT_TYPE_OVS,
190190
{'l2_agent_type': constants.AGENT_TYPE_OVS,
191-
'mech_drivers': 'openvswitch,linuxbridge',
191+
'mech_drivers': 'openvswitch',
192192
'placement_port': '8080'}),
193193
(constants.AGENT_TYPE_NIC_SWITCH,
194194
{'l2_agent_type': constants.AGENT_TYPE_NIC_SWITCH,

neutron/tests/fullstack/test_connectivity.py

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020
import testscenarios
2121

2222
from neutron.common import utils as common_utils
23-
from neutron.tests import base as tests_base
2423
from neutron.tests.common import net_helpers
2524
from neutron.tests.fullstack import base
2625
from neutron.tests.fullstack.resources import config
@@ -150,22 +149,6 @@ def test_controller_timeout_does_not_break_connectivity_sigkill(self):
150149
signal.SIGKILL)
151150

152151

153-
class TestLinuxBridgeConnectivitySameNetwork(BaseConnectivitySameNetworkTest):
154-
155-
l2_agent_type = constants.AGENT_TYPE_LINUXBRIDGE
156-
scenarios = [
157-
('VXLAN', {'network_type': 'vxlan',
158-
'l2_pop': False}),
159-
('VLANs', {'network_type': 'vlan',
160-
'l2_pop': False}),
161-
('VXLAN and l2pop', {'network_type': 'vxlan',
162-
'l2_pop': True})
163-
]
164-
165-
def test_connectivity(self):
166-
self._test_connectivity()
167-
168-
169152
class _TestUninterruptedConnectivityOnL2AgentRestart(
170153
BaseConnectivitySameNetworkTest):
171154

@@ -210,20 +193,3 @@ class TestUninterruptedConnectivityOnL2AgentRestartOvs(
210193

211194
def test_l2_agent_restart(self, agent_restart_timeout=20):
212195
self._test_l2_agent_restart(agent_restart_timeout)
213-
214-
215-
class TestUninterruptedConnectivityOnL2AgentRestartLB(
216-
_TestUninterruptedConnectivityOnL2AgentRestart):
217-
218-
scenario = [('LB',
219-
{'l2_agent_type': constants.AGENT_TYPE_LINUXBRIDGE})]
220-
221-
scenarios = (
222-
testscenarios.multiply_scenarios(
223-
scenario,
224-
_TestUninterruptedConnectivityOnL2AgentRestart.network_scenarios)
225-
)
226-
227-
@tests_base.unstable_test("bug 1928764")
228-
def test_l2_agent_restart(self, agent_restart_timeout=20):
229-
self._test_l2_agent_restart(agent_restart_timeout)

neutron/tests/fullstack/test_dhcp_agent.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,6 @@ class BaseDhcpAgentTest(base.BaseFullStackTestCase):
3333
scenarios = [
3434
(constants.AGENT_TYPE_OVS,
3535
{'l2_agent_type': constants.AGENT_TYPE_OVS}),
36-
(constants.AGENT_TYPE_LINUXBRIDGE,
37-
{'l2_agent_type': constants.AGENT_TYPE_LINUXBRIDGE})
3836
]
3937
boot_vm_for_test = True
4038
dhcp_scheduler_class = None

neutron/tests/fullstack/test_port_shut_down.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,6 @@ class PortShutDownTest(base.BaseFullStackTestCase):
3737
num_hosts = 1
3838

3939
scenarios = [
40-
(constants.AGENT_TYPE_LINUXBRIDGE,
41-
{'l2_agent_type': constants.AGENT_TYPE_LINUXBRIDGE}),
4240
(constants.AGENT_TYPE_OVS,
4341
{'l2_agent_type': constants.AGENT_TYPE_OVS})
4442
]

neutron/tests/fullstack/test_ports_rebind.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,6 @@ class TestPortsRebind(base.BaseFullStackTestCase):
3232
('Open vSwitch Agent', {
3333
'l2_agent_type': constants.AGENT_TYPE_OVS,
3434
'l2_mechdriver_name': 'openvswitch',
35-
}),
36-
('Linux Bridge Agent', {
37-
'l2_agent_type': constants.AGENT_TYPE_LINUXBRIDGE,
38-
'l2_mechdriver_name': 'linuxbridge',
3935
})]
4036

4137
def setUp(self):
@@ -170,9 +166,6 @@ def test_vm_port_rebound_when_L2_agent_revived(self):
170166
5. Router's port created in p.3 should be now bound properly
171167
"""
172168

173-
if self.l2_agent_type == constants.AGENT_TYPE_LINUXBRIDGE:
174-
self.skipTest("Bug 1798085")
175-
176169
gw_port = self.safe_client.client.list_ports(
177170
device_id=self.router['id'],
178171
device_owner=constants.DEVICE_OWNER_ROUTER_GW)['ports'][0]

neutron/tests/fullstack/test_qos.py

Lines changed: 0 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020
from neutronclient.common import exceptions
2121
from oslo_utils import uuidutils
2222

23-
from neutron.agent.linux import tc_lib
2423
from neutron.common import utils
2524
from neutron.tests.common.agents import l2_extensions
2625
from neutron.tests.fullstack import base
@@ -30,11 +29,6 @@
3029
from neutron.tests.unit import testlib_api
3130

3231
from neutron.agent.common import ovs_lib
33-
from neutron.conf.plugins.ml2.drivers import linuxbridge as \
34-
linuxbridge_agent_config
35-
from neutron.plugins.ml2.drivers.linuxbridge.agent import \
36-
linuxbridge_neutron_agent as linuxbridge_agent
37-
from neutron.services.qos.drivers.linuxbridge import driver as lb_drv
3832
from neutron.services.qos.drivers.openvswitch import driver as ovs_drv
3933

4034

@@ -404,46 +398,6 @@ def test_bw_limit_qos_port_removed(self):
404398
self.assertIsNone(qos_queues)
405399

406400

407-
class TestBwLimitQoSLinuxbridge(_TestBwLimitQoS, base.BaseFullStackTestCase):
408-
l2_agent_type = constants.AGENT_TYPE_LINUXBRIDGE
409-
scenarios = [
410-
('egress', {'direction': constants.EGRESS_DIRECTION}),
411-
('ingress', {'direction': constants.INGRESS_DIRECTION}),
412-
]
413-
414-
@staticmethod
415-
def _get_expected_burst_value(limit, direction):
416-
# For egress bandwidth limit this value should be calculated as
417-
# bandwidth_limit * qos_consts.DEFAULT_BURST_RATE
418-
if direction == constants.EGRESS_DIRECTION:
419-
return TestBwLimitQoSLinuxbridge._get_expected_egress_burst_value(
420-
limit)
421-
else:
422-
return TestBwLimitQoSLinuxbridge._get_expected_ingress_burst_value(
423-
limit)
424-
425-
@staticmethod
426-
def _get_expected_ingress_burst_value(limit):
427-
return int(
428-
float(limit) /
429-
float(linuxbridge_agent_config.DEFAULT_KERNEL_HZ_VALUE))
430-
431-
def _wait_for_bw_rule_applied(self, vm, limit, burst, direction):
432-
port_name = linuxbridge_agent.LinuxBridgeManager.get_tap_device_name(
433-
vm.neutron_port['id'])
434-
tc = tc_lib.TcCommand(
435-
port_name,
436-
linuxbridge_agent_config.DEFAULT_KERNEL_HZ_VALUE,
437-
namespace=vm.host.host_namespace
438-
)
439-
if direction == constants.EGRESS_DIRECTION:
440-
utils.wait_until_true(
441-
lambda: tc.get_filters_bw_limits() == (limit, burst))
442-
elif direction == constants.INGRESS_DIRECTION:
443-
utils.wait_until_true(
444-
lambda: tc.get_tbf_bw_limits() == (limit, burst))
445-
446-
447401
class _TestDscpMarkingQoS(BaseQoSRuleTestCase):
448402

449403
number_of_hosts = 2
@@ -540,15 +494,6 @@ def _wait_for_dscp_marking_rule_applied(self, vm, dscp_mark):
540494
vm.bridge, vm.port.name, dscp_mark)
541495

542496

543-
class TestDscpMarkingQoSLinuxbridge(_TestDscpMarkingQoS,
544-
base.BaseFullStackTestCase):
545-
l2_agent_type = constants.AGENT_TYPE_LINUXBRIDGE
546-
547-
def _wait_for_dscp_marking_rule_applied(self, vm, dscp_mark):
548-
l2_extensions.wait_until_dscp_marking_rule_applied_linuxbridge(
549-
vm.host.host_namespace, vm.port.name, dscp_mark)
550-
551-
552497
class _TestPacketRateLimitQoS(BaseQoSRuleTestCase):
553498

554499
number_of_hosts = 1
@@ -644,9 +589,6 @@ class TestQoSWithL2Population(base.BaseFullStackTestCase):
644589
(constants.AGENT_TYPE_OVS,
645590
{'mech_drivers': 'openvswitch',
646591
'supported_rules': ovs_drv.SUPPORTED_RULES}),
647-
(constants.AGENT_TYPE_LINUXBRIDGE,
648-
{'mech_drivers': 'linuxbridge',
649-
'supported_rules': lb_drv.SUPPORTED_RULES})
650592
]
651593

652594
def setUp(self):

neutron/tests/fullstack/test_securitygroup.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,6 @@ class TestSecurityGroupsSameNetwork(BaseSecurityGroupsSameNetworkTest):
9494

9595
network_type = 'vxlan'
9696
scenarios = [
97-
# TODO(njohnston): Re-add the linuxbridge scenario once it is stable
98-
# The iptables_hybrid driver lacks isolation between agents and
99-
# because of that using only one host is enough
10097
('ovs-hybrid', {
10198
'firewall_driver': 'iptables_hybrid',
10299
'l2_agent_type': constants.AGENT_TYPE_OVS,

neutron/tests/fullstack/test_segmentation_id.py

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
# under the License.
1212

1313
from neutron_lib import constants
14-
from neutronclient.common import exceptions
1514
from oslo_utils import uuidutils
1615

1716
from neutron.tests.common.agents import l2_extensions
@@ -72,8 +71,7 @@ class TestSegmentationId(BaseSegmentationIdTest):
7271

7372
scenarios = [
7473
('Open vSwitch Agent', {'l2_agent_type': constants.AGENT_TYPE_OVS}),
75-
('Linux Bridge Agent', {
76-
'l2_agent_type': constants.AGENT_TYPE_LINUXBRIDGE})]
74+
]
7775
num_hosts = 1
7876

7977
def test_change_segmentation_id_no_ports_in_network(self):
@@ -103,13 +101,7 @@ def test_change_segmentation_id_with_bound_ports_in_network(self):
103101
self.safe_client.create_port(self.project_id, network['id'],
104102
self.environment.hosts[0].hostname)
105103

106-
if self.l2_agent_type == constants.AGENT_TYPE_LINUXBRIDGE:
107-
# Linuxbridge agent don't support update of segmentation_id for
108-
# the network so this should raise an exception
109-
self.assertRaises(exceptions.BadRequest,
110-
self._update_segmentation_id, network)
111-
else:
112-
self._update_segmentation_id(network)
104+
self._update_segmentation_id(network)
113105

114106

115107
class TestSegmentationIdConnectivity(BaseSegmentationIdTest):

0 commit comments

Comments
 (0)