--- /dev/null
+/*\r
+* ============LICENSE_START=======================================================\r
+* ONAP : SO\r
+* ================================================================================\r
+* Copyright 2018 TechMahindra\r
+*=================================================================================\r
+* Licensed under the Apache License, Version 2.0 (the "License");\r
+* you may not use this file except in compliance with the License.\r
+* You may obtain a copy of the License at\r
+*\r
+* http://www.apache.org/licenses/LICENSE-2.0\r
+*\r
+* Unless required by applicable law or agreed to in writing, software\r
+* distributed under the License is distributed on an "AS IS" BASIS,\r
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+* See the License for the specific language governing permissions and\r
+* limitations under the License.\r
+* ============LICENSE_END=========================================================\r
+*/\r
+package org.openecomp.mso.apihandlerinfra.volumebeans;\r
+\r
+import static org.junit.Assert.*;\r
+\r
+import org.junit.Test;\r
+\r
+public class ObjectFactoryTest {\r
+ ObjectFactory of = new ObjectFactory();\r
+ Object o = new Object();\r
+ @Test\r
+ public void testObjectFactory() {\r
+ of.createRequestInfo();\r
+ of.createVolumeRequest();\r
+ of.createVolumeInputs();\r
+ of.createVolumeOutputs();\r
+ of.createVolumeRequests();\r
+ of.createVolumeParams(o);\r
+ }\r
+}\r
--- /dev/null
+/*\r
+* ============LICENSE_START=======================================================\r
+* ONAP : SO\r
+* ================================================================================\r
+* Copyright 2018 TechMahindra\r
+*=================================================================================\r
+* Licensed under the Apache License, Version 2.0 (the "License");\r
+* you may not use this file except in compliance with the License.\r
+* You may obtain a copy of the License at\r
+*\r
+* http://www.apache.org/licenses/LICENSE-2.0\r
+*\r
+* Unless required by applicable law or agreed to in writing, software\r
+* distributed under the License is distributed on an "AS IS" BASIS,\r
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+* See the License for the specific language governing permissions and\r
+* limitations under the License.\r
+* ============LICENSE_END=========================================================\r
+*/\r
+package org.openecomp.mso.apihandlerinfra.volumebeans;\r
+\r
+import static org.junit.Assert.*;\r
+\r
+import org.junit.Test;\r
+\r
+public class RequestInfoTest {\r
+ RequestInfo ri = new RequestInfo();\r
+ ActionType actiontype = ActionType.CREATE;\r
+ RequestStatusType requestStatustype = RequestStatusType.COMPLETE;\r
+ int abc;\r
+ @Test\r
+ public void testRequestInfo() {\r
+ ri.setRequestId("requestId");\r
+ ri.setAction(actiontype);\r
+ ri.setRequestStatus(requestStatustype);\r
+ ri.setStatusMessage("statusMessage");\r
+ ri.setProgress(abc);\r
+ ri.setStartTime("startTime");\r
+ ri.setEndTime("endTime");\r
+ ri.setSource("source");\r
+ assertEquals(ri.getRequestId(), "requestId");\r
+ assertEquals(ri.getAction(), actiontype);\r
+ assertEquals(ri.getRequestStatus(), requestStatustype);\r
+ assertEquals(ri.getStatusMessage(), "statusMessage");\r
+ assert(ri.getProgress().equals(abc));\r
+ assertEquals(ri.getStartTime(), "startTime");\r
+ assertEquals(ri.getEndTime(), "endTime");\r
+ assertEquals(ri.getSource(), "source"); \r
+ }\r
+}\r
--- /dev/null
+/*\r
+* ============LICENSE_START=======================================================\r
+* ONAP : SO\r
+* ================================================================================\r
+* Copyright 2018 TechMahindra\r
+*=================================================================================\r
+* Licensed under the Apache License, Version 2.0 (the "License");\r
+* you may not use this file except in compliance with the License.\r
+* You may obtain a copy of the License at\r
+*\r
+* http://www.apache.org/licenses/LICENSE-2.0\r
+*\r
+* Unless required by applicable law or agreed to in writing, software\r
+* distributed under the License is distributed on an "AS IS" BASIS,\r
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+* See the License for the specific language governing permissions and\r
+* limitations under the License.\r
+* ============LICENSE_END=========================================================\r
+*/\r
+package org.openecomp.mso.apihandlerinfra.volumebeans;\r
+\r
+import static org.junit.Assert.*;\r
+\r
+import org.junit.Test;\r
+\r
+public class VolumeInputsTest {\r
+ \r
+ VolumeInputs vi = new VolumeInputs();\r
+ @Test\r
+ public void testVolumeInputs() {\r
+ vi.setVolumeGroupId("volumeGroupId");\r
+ vi.setVolumeGroupName("volumeGroupName");\r
+ vi.setVnfType("vnfType");\r
+ vi.setVnfId("vnfId");\r
+ vi.setServiceInstanceId("serviceInstanceId");\r
+ vi.setServiceType("serviceType");\r
+ vi.setServiceId("serviceId");\r
+ vi.setAicNodeClli("aicNodeClli");\r
+ vi.setAicCloudRegion("aicCloudRegion");\r
+ vi.setTenantId("tenantId");\r
+ vi.setVfModuleModelName("vfModuleModelName");\r
+ vi.setAsdcServiceModelVersion("asdcServiceModelVersion");\r
+ vi.setBackoutOnFailure(true);\r
+ assertEquals(vi.getVolumeGroupId(), "volumeGroupId");\r
+ assertEquals(vi.getVolumeGroupName(), "volumeGroupName");\r
+ assertEquals(vi.getVnfType(), "vnfType");\r
+ assertEquals(vi.getVnfId(), "vnfId");\r
+ assertEquals(vi.getServiceInstanceId(), "serviceInstanceId");\r
+ assertEquals(vi.getServiceType(), "serviceType");\r
+ assertEquals(vi.getServiceId(), "serviceId");\r
+ assertEquals(vi.getAicNodeClli(), "aicNodeClli");\r
+ assertEquals(vi.getAicCloudRegion(), "aicCloudRegion");\r
+ assertEquals(vi.getTenantId(), "tenantId");\r
+ assertEquals(vi.getVfModuleModelName(), "vfModuleModelName");\r
+ assertEquals(vi.getAsdcServiceModelVersion(), "asdcServiceModelVersion");\r
+ assertEquals(vi.getBackoutOnFailure(), true); \r
+ }\r
+}\r
--- /dev/null
+/*\r
+* ============LICENSE_START=======================================================\r
+* ONAP : SO\r
+* ================================================================================\r
+* Copyright 2018 TechMahindra\r
+*=================================================================================\r
+* Licensed under the Apache License, Version 2.0 (the "License");\r
+* you may not use this file except in compliance with the License.\r
+* You may obtain a copy of the License at\r
+*\r
+* http://www.apache.org/licenses/LICENSE-2.0\r
+*\r
+* Unless required by applicable law or agreed to in writing, software\r
+* distributed under the License is distributed on an "AS IS" BASIS,\r
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+* See the License for the specific language governing permissions and\r
+* limitations under the License.\r
+* ============LICENSE_END=========================================================\r
+*/\r
+package org.openecomp.mso.apihandlerinfra.volumebeans;\r
+\r
+import static org.junit.Assert.*;\r
+\r
+import org.junit.Test;\r
+\r
+public class VolumeOutputsTest {\r
+ \r
+ VolumeOutputs vo = new VolumeOutputs();\r
+ @Test\r
+ public void testVolumeOutputs() {\r
+ vo.setVolumeGroupId("volumeGroupId");\r
+ vo.setVolumeGroupName("volumeGroupName");\r
+ vo.setVnfType("vnfType");\r
+ vo.setServiceType("serviceType");\r
+ vo.setAicNodeClli("aicNodeClli");\r
+ vo.setTenantId("tenantId");\r
+ assertEquals(vo.getVolumeGroupId(), "volumeGroupId");\r
+ assertEquals(vo.getVolumeGroupName(), "volumeGroupName");\r
+ assertEquals(vo.getVnfType(), "vnfType");\r
+ assertEquals(vo.getServiceType(), "serviceType");\r
+ assertEquals(vo.getAicNodeClli(), "aicNodeClli");\r
+ assertEquals(vo.getTenantId(), "tenantId"); \r
+ }\r
+}\r
--- /dev/null
+/*\r
+* ============LICENSE_START=======================================================\r
+* ONAP : SO\r
+* ================================================================================\r
+* Copyright 2018 TechMahindra\r
+*=================================================================================\r
+* Licensed under the Apache License, Version 2.0 (the "License");\r
+* you may not use this file except in compliance with the License.\r
+* You may obtain a copy of the License at\r
+*\r
+* http://www.apache.org/licenses/LICENSE-2.0\r
+*\r
+* Unless required by applicable law or agreed to in writing, software\r
+* distributed under the License is distributed on an "AS IS" BASIS,\r
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+* See the License for the specific language governing permissions and\r
+* limitations under the License.\r
+* ============LICENSE_END=========================================================\r
+*/\r
+package org.openecomp.mso.apihandlerinfra.volumebeans;\r
+\r
+import static org.junit.Assert.*;\r
+\r
+import org.junit.Test;\r
+\r
+public class VolumeRequestTest {\r
+ \r
+ VolumeRequest vr = new VolumeRequest();\r
+ RequestInfo ri = new RequestInfo();\r
+ VolumeInputs vi = new VolumeInputs();\r
+ VolumeOutputs vo = new VolumeOutputs();\r
+ Object o = new Object();\r
+ @Test\r
+ public void testVolumeRequest() {\r
+ vr.setRequestInfo(ri);\r
+ vr.setVolumeInputs(vi);\r
+ vr.setVolumeOutputs(vo);\r
+ vr.setVolumeParams(o);\r
+ assertEquals(vr.getRequestInfo(), ri);\r
+ assertEquals(vr.getVolumeInputs(), vi);\r
+ assertEquals(vr.getVolumeOutputs(), vo);\r
+ assertEquals(vr.getVolumeParams(), o); \r
+ }\r
+}\r
--- /dev/null
+/*\r
+* ============LICENSE_START=======================================================\r
+* ONAP : SO\r
+* ================================================================================\r
+* Copyright 2018 TechMahindra\r
+*=================================================================================\r
+* Licensed under the Apache License, Version 2.0 (the "License");\r
+* you may not use this file except in compliance with the License.\r
+* You may obtain a copy of the License at\r
+*\r
+* http://www.apache.org/licenses/LICENSE-2.0\r
+*\r
+* Unless required by applicable law or agreed to in writing, software\r
+* distributed under the License is distributed on an "AS IS" BASIS,\r
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+* See the License for the specific language governing permissions and\r
+* limitations under the License.\r
+* ============LICENSE_END=========================================================\r
+*/\r
+package org.openecomp.mso.apihandlerinfra.volumebeans;\r
+\r
+import static org.junit.Assert.*;\r
+\r
+import org.junit.Test;\r
+\r
+public class VolumeRequestsTest {\r
+ VolumeRequests vrs = new VolumeRequests();\r
+ @Test\r
+ public void testVolumeRequests() {\r
+ vrs.getVolumeRequest(); \r
+ }\r
+}\r