add nagative unittest for program deployable in cyborg module
add negative unittest for program deployable in cyborg module Change-Id: I19e5ee245e71fc847541c75a350aff876a8e74f1
This commit is contained in:
parent
dfff42177f
commit
51c06d55f1
|
@ -203,3 +203,14 @@ class TestDeployableProgram(TestDeployable):
|
|||
exc.CommandError,
|
||||
'image not found: %s' % acc_fakes.image_uuid,
|
||||
self.cmd.take_action, parsed_args)
|
||||
|
||||
def test_deployable_program_with_deployable_uuid_not_exist(self):
|
||||
get_arq_req = self.mock_acc_client.get_deployable
|
||||
get_arq_req.side_effect = sdk_exc.ResourceNotFound
|
||||
arglist = [acc_fakes.deployable_uuid, acc_fakes.image_uuid]
|
||||
verifylist = []
|
||||
parsed_args = self.check_parser(self.cmd, arglist, verifylist)
|
||||
self.assertRaisesRegex(
|
||||
exc.CommandError,
|
||||
'deployable not found: %s' % acc_fakes.deployable_uuid,
|
||||
self.cmd.take_action, parsed_args)
|
||||
|
|
Loading…
Reference in New Issue