diff options
author | maopengzhang <zhang.maopeng1@zte.com.cn> | 2018-11-14 16:34:33 +0800 |
---|---|---|
committer | maopengzhang <zhang.maopeng1@zte.com.cn> | 2018-11-14 16:51:56 +0800 |
commit | 67fb6e372b7023f5cda39b4c8025488fa894cdef (patch) | |
tree | 628cca3f09abedd0caeca349deab9d4ed91d7281 | |
parent | 49d61647a45a8bb27c2ca4605e5d356fa524731b (diff) |
fix NS update error
fix NS update error in Driver
Change-Id: I36f6722828423445cc20258aed775dc0fdab015e
Issue-ID: VFC-1185
Signed-off-by: maopengzhang <zhang.maopeng1@zte.com.cn>
-rw-r--r-- | gvnfmadapter/driver/interfaces/tests.py | 1 | ||||
-rw-r--r-- | gvnfmadapter/driver/interfaces/views.py | 2 |
2 files changed, 1 insertions, 2 deletions
diff --git a/gvnfmadapter/driver/interfaces/tests.py b/gvnfmadapter/driver/interfaces/tests.py index 61c8941..4580680 100644 --- a/gvnfmadapter/driver/interfaces/tests.py +++ b/gvnfmadapter/driver/interfaces/tests.py @@ -812,7 +812,6 @@ class InterfacesTest(TestCase): response = self.client.post("/api/gvnfmdriver/v1/vnfmid/vnfs/2/operate", data=json.dumps(req_data), content_type="application/json") self.assertEqual(status.HTTP_202_ACCEPTED, response.status_code) - self.assertEqual(None, response.data) self.assertEqual("/vnf_lc_ops/NF-OPERATE-12-2a3be946-b01d-11e8-9302-08002705b121", response['Location']) # Heal API diff --git a/gvnfmadapter/driver/interfaces/views.py b/gvnfmadapter/driver/interfaces/views.py index 15e1c31..689446a 100644 --- a/gvnfmadapter/driver/interfaces/views.py +++ b/gvnfmadapter/driver/interfaces/views.py @@ -333,7 +333,7 @@ class VnfOperateView(APIView): return Response(data=resp, status=status.HTTP_404_NOT_FOUND) elif ret == status.HTTP_409_CONFLICT: return Response(data=resp, status=status.HTTP_409_CONFLICT) - response = Response(data=None, status=status.HTTP_202_ACCEPTED) + response = Response(data=resp, status=status.HTTP_202_ACCEPTED) response["Location"] = location return response except GvnfmDriverException as e: |