File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
neutron/tests/functional/agent Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change 2020import eventlet
2121import fixtures
2222import netaddr
23+ from neutron_lib .api import converters
2324from neutron_lib import constants as lib_const
2425from oslo_config import fixture as fixture_config
2526from oslo_utils import uuidutils
4243
4344class DHCPAgentOVSTestFramework (base .BaseSudoTestCase ):
4445
45- _DHCP_PORT_MAC_ADDRESS = netaddr . EUI ( "24:77:03:7d:00:4c" )
46- _DHCP_PORT_MAC_ADDRESS . dialect = netaddr . mac_unix
47- _TENANT_PORT_MAC_ADDRESS = netaddr . EUI ( "24:77:03:7d:00:3a" )
48- _TENANT_PORT_MAC_ADDRESS . dialect = netaddr . mac_unix
46+ _DHCP_PORT_MAC_ADDRESS = converters . convert_to_sanitized_mac_address (
47+ '24:77:03:7d:00:4c' )
48+ _TENANT_PORT_MAC_ADDRESS = converters . convert_to_sanitized_mac_address (
49+ '24:77:03:7d:00:3a' )
4950
5051 _IP_ADDRS = {
5152 4 : {'addr' : '192.168.10.11' ,
@@ -307,9 +308,8 @@ def test_bad_address_allocation(self):
307308 network , port = self ._get_network_port_for_allocation_test ()
308309 network .ports .append (port )
309310 self .configure_dhcp_for_network (network = network )
310- bad_mac_address = netaddr .EUI (self ._TENANT_PORT_MAC_ADDRESS .value + 1 )
311- bad_mac_address .dialect = netaddr .mac_unix
312- port .mac_address = str (bad_mac_address )
311+ port .mac_address = converters .convert_to_sanitized_mac_address (
312+ '24:77:03:7d:00:4d' )
313313 self ._plug_port_for_dhcp_request (network , port )
314314 self .assert_bad_allocation_for_port (network , port )
315315
You can’t perform that action at this time.
0 commit comments