Merge "[tempest] also catch BadRequest in negative tests with physical_network in old API"

This commit is contained in:
Jenkins 2017-08-04 19:24:11 +00:00 committed by Gerrit Code Review
commit afc0dd7ccc

View File

@ -354,7 +354,7 @@ class TestPortsWithPhysicalNetworkOldAPI(base.BaseBaremetalTest):
node_id = self.node['uuid']
address = data_utils.rand_mac_address()
self.assertRaises(lib_exc.UnexpectedResponseCode,
self.assertRaises((lib_exc.BadRequest, lib_exc.UnexpectedResponseCode),
self.create_port,
node_id=node_id, address=address,
physical_network='physnet1')
@ -371,7 +371,7 @@ class TestPortsWithPhysicalNetworkOldAPI(base.BaseBaremetalTest):
'op': 'replace',
'value': new_physnet}]
self.assertRaises(lib_exc.UnexpectedResponseCode,
self.assertRaises((lib_exc.BadRequest, lib_exc.UnexpectedResponseCode),
self.client.update_port,
port['uuid'], patch)