added test case to PropertyOperatorTest.java 49/66449/1
authorSandeep J <sandeejh@in.ibm.com>
Thu, 13 Sep 2018 19:35:39 +0000 (01:05 +0530)
committerSandeep J <sandeejh@in.ibm.com>
Thu, 13 Sep 2018 19:44:18 +0000 (01:14 +0530)
to increase code coverage

Issue-ID: CCSDK-552
Change-Id: I9efbb57491b6b6c53447dbb77da97d5a62c93481
Signed-off-by: Sandeep J <sandeejh@in.ibm.com>
ms/neng/src/test/java/org/onap/ccsdk/apps/ms/neng/core/policy/PropertyOperatorTest.java

index 9d6c3f9..38d44f1 100644 (file)
@@ -4,6 +4,8 @@
  * ================================================================================
  * Copyright (C) 2018 AT&T Intellectual Property. All rights reserved.
  * ================================================================================
+ * Modifications Copyright (C) 2018 IBM.
+ * ================================================================================
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  * You may obtain a copy of the License at
@@ -21,6 +23,7 @@
 package org.onap.ccsdk.apps.ms.neng.core.policy;
 
 import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNull;
 import static org.mockito.Mockito.mock;
 import static org.mockito.Mockito.when;
 
@@ -72,6 +75,12 @@ public class PropertyOperatorTest {
         PropertyOperator op = new PropertyOperator();
         assertEquals("ASDF", op.apply("asdf", props, params));
     }
+    
+    @Test
+    public void testApply() throws Exception {
+        PropertyOperator op = new PropertyOperator();
+        assertNull("ASDF", op.apply("asdf", "", params));
+    }
 
     @Test
     public void applySubstr() throws Exception {