added test case to TestDGGeneralDBService 96/77496/1
authorSandeep J <sandeejh@in.ibm.com>
Tue, 29 Jan 2019 08:40:53 +0000 (14:10 +0530)
committerSandeep J <sandeejh@in.ibm.com>
Tue, 29 Jan 2019 08:42:06 +0000 (14:12 +0530)
to increase code coverage

Issue-ID: APPC-1086
Change-Id: I1e1d12fd230ea45b3618e41a7416a35cbf64fe0c
Signed-off-by: Sandeep J <sandeejh@in.ibm.com>
appc-config/appc-data-services/provider/src/test/java/org/onap/appc/data/services/db/TestDGGeneralDBService.java

index 9780961..0af63f3 100644 (file)
@@ -338,4 +338,17 @@ public class TestDGGeneralDBService {
         QueryStatus status= dbService.saveUploadConfig(ctx, "test");
         assertEquals(QueryStatus.SUCCESS, status);
     }
+    
+    @Test
+    public void testUpdateUploadConfig() throws SvcLogicException
+    {
+        SvcLogicContext ctx = new SvcLogicContext();
+        
+        ctx.setAttribute("vnf-type", "test");
+        ctx.setAttribute("vnfc-type", "test");
+        
+        MockDGGeneralDBService dbService =     MockDGGeneralDBService.initialise();
+        QueryStatus status= dbService.updateUploadConfig(ctx, "test",10);
+        assertEquals(QueryStatus.SUCCESS, status);
+    }
 }