From c43fcb791d0b1f2de826e3e997b9680d6e2edca7 Mon Sep 17 00:00:00 2001 From: fujinhua Date: Tue, 23 Apr 2019 10:23:21 +0800 Subject: Add scale to levle ut case Change-Id: I6182ad75e7894a1db7af13a79fe8f6e69b330e66 Issue-ID: VFC-1306 Signed-off-by: fujinhua --- lcm/lcm/nf/tests/test_scale_vnf_to_level.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/lcm/lcm/nf/tests/test_scale_vnf_to_level.py b/lcm/lcm/nf/tests/test_scale_vnf_to_level.py index 36eeba41..657a19ff 100644 --- a/lcm/lcm/nf/tests/test_scale_vnf_to_level.py +++ b/lcm/lcm/nf/tests/test_scale_vnf_to_level.py @@ -52,3 +52,21 @@ class TestNfScaleToLevel(TestCase): data=self.req_data, format='json') self.failUnlessEqual(status.HTTP_409_CONFLICT, response.status_code) + + def test_scale_to_level_inner_error(self): + NfInstModel(nfinstid='678', + nf_name='VNF1', + nf_desc="VNF DESC", + vnfdid="1", + netype="XGW", + vendor="ZTE", + vnfSoftwareVersion="V1", + version="V1", + package_id="2", + status='INSTANTIATED').save() + url = "/api/vnflcm/v1/vnf_instances/678/scale_to_level" + response = self.client.post(url, + data={}, + format='json') + NfInstModel.objects.filter(nfinstid='678').delete() + self.failUnlessEqual(status.HTTP_500_INTERNAL_SERVER_ERROR, response.status_code) -- cgit 1.2.3-korg