Modify test workaround for extra_dhcp_opts
The neutron create API now returns extra_dhcp_opts. In older versions it did not so it had to be removed when comparing the port definitions between the "create" and the "get". Now we only remove it if it is not present in the "create". This keeps it working for our keystonev2 test job which runs against stable/liberty now. Change-Id: I4d6a57b0f15f1868c5ba4e62a2bf248662bd8896
This commit is contained in:
@@ -89,7 +89,7 @@ class TestPort(base.TestCase):
|
||||
|
||||
updated_port = self.cloud.get_port(name_or_id=port['id'])
|
||||
# extra_dhcp_opts is added later by Neutron...
|
||||
if 'extra_dhcp_opts' in updated_port:
|
||||
if 'extra_dhcp_opts' in updated_port and 'extra_dhcp_opts' not in port:
|
||||
del updated_port['extra_dhcp_opts']
|
||||
self.assertEqual(port, updated_port)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user