diff options
author | Seshu Kumar M <seshu.kumar.m@huawei.com> | 2017-09-19 08:55:00 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2017-09-19 08:55:00 +0000 |
commit | f5886ace0971372d0173bf7f53c56c0d2cccbfcd (patch) | |
tree | cf6d8a132dc001545f0f0494118b3c520169aacb | |
parent | be8679eda099ff56571b9c8afcc12fcb52fea48b (diff) | |
parent | 02def185d8e90385aeefe4ba23ed79942aaff921 (diff) |
Merge "Add UT for delete API"
-rw-r--r-- | adapters/mso-vfc-adapter/src/test/java/org/openecomp/mso/adapters/vfc/VfcAdapterTest.java | 8 | ||||
-rw-r--r-- | adapters/mso-vfc-adapter/src/test/resources/json/deleteNsReq.json | 2 |
2 files changed, 8 insertions, 2 deletions
diff --git a/adapters/mso-vfc-adapter/src/test/java/org/openecomp/mso/adapters/vfc/VfcAdapterTest.java b/adapters/mso-vfc-adapter/src/test/java/org/openecomp/mso/adapters/vfc/VfcAdapterTest.java index 1777dea0dc..dc07a3cb36 100644 --- a/adapters/mso-vfc-adapter/src/test/java/org/openecomp/mso/adapters/vfc/VfcAdapterTest.java +++ b/adapters/mso-vfc-adapter/src/test/java/org/openecomp/mso/adapters/vfc/VfcAdapterTest.java @@ -99,7 +99,9 @@ public class VfcAdapterTest { return getResponse("createNsRsp.json"); } else if(url.contains("instantiate") && methodType.equals(CommonConstant.MethodType.POST)) { return getResponse("instantiateNsRsp.json"); - } else { + } else if(methodType.equals(CommonConstant.MethodType.DELETE)) { + return getResponse(null); + }else { return null; } } @@ -177,7 +179,9 @@ public class VfcAdapterTest { @Test public void deleteTest() { - + // get request + mockRestfulUtil(FILE_PATH + "deleteNsReq.json"); + vfcAdapter.deleteNfvoNs(null, "9b9f02c0-298b-458a-bc9c-be3692e4f354"); } @Test diff --git a/adapters/mso-vfc-adapter/src/test/resources/json/deleteNsReq.json b/adapters/mso-vfc-adapter/src/test/resources/json/deleteNsReq.json index 4f7c29f9d0..ac095e6aa3 100644 --- a/adapters/mso-vfc-adapter/src/test/resources/json/deleteNsReq.json +++ b/adapters/mso-vfc-adapter/src/test/resources/json/deleteNsReq.json @@ -1,4 +1,6 @@ { + "globalSubscriberId":"9b9f02c0-298b-458a-bc9c-be3692e4f350", + "serviceType":"service", "serviceId":"9b9f02c0-298b-458a-bc9c-be3692e4f351", "operationId":"9b9f02c0-298b-458a-bc9c-be3692e4f352", "nodeTemplateUUID":"9b9f02c0-298b-458a-bc9c-be3692e4f353" |