diff options
author | Ethan Lynn <ethanlynnl@vmware.com> | 2018-03-26 21:58:24 -0700 |
---|---|---|
committer | Ethan Lynn <ethanlynnl@vmware.com> | 2018-03-26 21:58:24 -0700 |
commit | b804f9f12126ba3223928e1a05cba03c1c988bd0 (patch) | |
tree | 5aa2e6c3a4ae31f94b1e3b15ab6f189ce8bed5d1 /vio | |
parent | 98c3f5881a15cffc2e1f1541f99ca8ca3d744eab (diff) |
Add test_del_images
Add test_del_images for AAIClient
Change-Id: Ifb038777863d1ef89bcbb030a8568493638f4d58
Issue-ID: MULTICLOUD-199
Signed-off-by: Ethan Lynn <ethanlynnl@vmware.com>
Diffstat (limited to 'vio')
-rw-r--r-- | vio/vio/tests/test_aai_client.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/vio/vio/tests/test_aai_client.py b/vio/vio/tests/test_aai_client.py index 61eedd8..12ee35c 100644 --- a/vio/vio/tests/test_aai_client.py +++ b/vio/vio/tests/test_aai_client.py @@ -125,3 +125,17 @@ class TestAAIClient(unittest.TestCase): } self.view._del_flavors(rsp) mock_call.assert_called_once() + + @mock.patch.object(restcall, "call_req") + def test_del_images(self, mock_call): + mock_call.return_value = [0] + rsp = { + "images": { + "image": [{ + "image-id": "fake-id", + "resource-version": "fake-version" + }] + } + } + self.view._del_images(rsp) + mock_call.assert_called_once() |