summaryrefslogtreecommitdiffstats
path: root/generic-resource-api
diff options
context:
space:
mode:
authorDan Timoney <dtimoney@att.com>2019-08-12 13:12:01 +0000
committerGerrit Code Review <gerrit@onap.org>2019-08-12 13:12:01 +0000
commit8b69fffd6d7c514157f99c563681174e5acb8476 (patch)
treeb8dc78777bbbca89c16d184455b89e31e8e5b25f /generic-resource-api
parentc4b2da44aae39a591bf2c2bc83ccbbb5b556d17b (diff)
parentbe8e3f3da6f00427eb62616ac75fbd4d7f5ed4c6 (diff)
Merge "Test case addition for sdnc code coverage"
Diffstat (limited to 'generic-resource-api')
-rw-r--r--generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/GenericConfigurationNotificationRPCTest.java38
1 files changed, 38 insertions, 0 deletions
diff --git a/generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/GenericConfigurationNotificationRPCTest.java b/generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/GenericConfigurationNotificationRPCTest.java
new file mode 100644
index 00000000..5d611801
--- /dev/null
+++ b/generic-resource-api/provider/src/test/java/org/onap/sdnc/northbound/GenericConfigurationNotificationRPCTest.java
@@ -0,0 +1,38 @@
+package org.onap.sdnc.northbound;
+
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.runners.MockitoJUnitRunner;
+import org.opendaylight.yang.gen.v1.org.onap.sdnc.northbound.generic.resource.rev170824.GenericConfigurationNotificationInput;
+import org.opendaylight.yang.gen.v1.org.onap.sdnc.northbound.generic.resource.rev170824.GenericConfigurationNotificationOutput;
+import org.opendaylight.yangtools.yang.common.RpcResult;
+import org.opendaylight.yang.gen.v1.org.onap.sdnc.northbound.generic.resource.rev170824.service.information.ServiceInformationBuilder;
+
+import static org.junit.Assert.assertNull;
+import static org.onap.sdnc.northbound.util.MDSALUtil.*;
+
+@RunWith(MockitoJUnitRunner.class)
+public class GenericConfigurationNotificationRPCTest extends GenericResourceApiProviderTest {
+
+ private static final String SVC_OPERATION = "generic-configuration-notification";
+
+ @Before
+ public void setUp() throws Exception {
+ super.setUp();
+ svcClient.setScvOperation(SVC_OPERATION);
+ }
+
+ @Test
+ public void should_complete_with_success_when_no_errors() throws Exception {
+
+ GenericConfigurationNotificationInput input = build(GenericConfigurationNotificationInput()
+ .setServiceInformation(new ServiceInformationBuilder().setServiceInstanceId("serviceInstanceId").build()));
+
+ GenericConfigurationNotificationOutput output =
+ exec(genericResourceApiProvider::genericConfigurationNotification, input, RpcResult::getResult);
+
+ assertNull(output);
+ }
+}
+