add ut for delete attribute client exception error
add ut for delete attribute client exception error Change-Id: I9a1c3304df15fa4815a30b1b980566134788eb3c
This commit is contained in:
parent
51c06d55f1
commit
0b8f60cb02
|
@ -216,3 +216,13 @@ class TestAttributeDelete(TestAttribute):
|
|||
exc.CommandError,
|
||||
'Attribute %s not found' % acc_fakes.attribute_uuid,
|
||||
self.cmd.take_action, parsed_args)
|
||||
|
||||
def test_attribute_delete_for_client_exception(self):
|
||||
get_arq_req = self.mock_acc_client.delete_attribute
|
||||
get_arq_req.side_effect = exc.ClientException
|
||||
arglist = [acc_fakes.attribute_uuid]
|
||||
verifylist = []
|
||||
parsed_args = self.check_parser(self.cmd, arglist, verifylist)
|
||||
self.assertRaises(
|
||||
exc.ClientException,
|
||||
self.cmd.take_action, parsed_args)
|
||||
|
|
Loading…
Reference in New Issue