summaryrefslogtreecommitdiffstats
path: root/dmaap-listener
diff options
context:
space:
mode:
authorshashikanth.vh <shashikanth.vh@huawei.com>2018-03-26 19:24:35 +0530
committershashikanth.vh <shashikanth.vh@huawei.com>2018-03-27 18:28:36 +0530
commit22a9e045d42ad629010cc4200369a4453fbe0df7 (patch)
treef094c6903d9b3cf7de9e9d19fe2e847e30382995 /dmaap-listener
parent4bab4f2255a19f54aa3c18f5b51b2715f085d83c (diff)
coverageSdncFlatJsonDmaapConsumer
Coverage improvement for SdncFlatJsonDmaapConsumer https://jira.onap.org/browse/CCSDK-213?jql=project%20%3D%20CCSDK%20AND%20text%20~%20coverage Issue-ID: CCSDK-213 Change-Id: I95e824c5c83b9c36ce0c475368235182e851c254 Signed-off-by: shashikanth.vh <shashikanth.vh@huawei.com>
Diffstat (limited to 'dmaap-listener')
-rw-r--r--dmaap-listener/src/test/java/org/onap/ccsdk/sli/northbound/dmaapclient/TestSdncJsonDmaapConsumer.java12
1 files changed, 12 insertions, 0 deletions
diff --git a/dmaap-listener/src/test/java/org/onap/ccsdk/sli/northbound/dmaapclient/TestSdncJsonDmaapConsumer.java b/dmaap-listener/src/test/java/org/onap/ccsdk/sli/northbound/dmaapclient/TestSdncJsonDmaapConsumer.java
index 0d65231da..01bd3cf28 100644
--- a/dmaap-listener/src/test/java/org/onap/ccsdk/sli/northbound/dmaapclient/TestSdncJsonDmaapConsumer.java
+++ b/dmaap-listener/src/test/java/org/onap/ccsdk/sli/northbound/dmaapclient/TestSdncJsonDmaapConsumer.java
@@ -19,4 +19,16 @@ public class TestSdncJsonDmaapConsumer {
SdncFlatJsonDmaapConsumer consumer = new SdncFlatJsonDmaapConsumer();
consumer.processMsg(null);
}
+
+ @Test(expected = InvalidMessageException.class)
+ public void testProcessMsgNullFieldMap_shouldThrowException() throws Exception {
+ SdncFlatJsonDmaapConsumer consumer = new SdncFlatJsonDmaapConsumer();
+
+ String msg = "{\n" +
+ " \"input\" : { \n" +
+ " }\n" +
+ "}";
+
+ consumer.processMsg(msg);
+ }
}