diff options
author | Anand Chaturvedi <ac204h@att.com> | 2017-08-24 00:10:17 -0400 |
---|---|---|
committer | Anand Chaturvedi <ac204h@att.com> | 2017-08-24 01:01:46 -0400 |
commit | 96119e62a35496ecb0093c0f55300dffb95c8d33 (patch) | |
tree | 64874a9c7dd5792185237a7e4164f2c025a7fde5 /appc-config/appc-data-services/provider/src/test | |
parent | f0f51b3047ea290e2280af64b39ca0983f3377f5 (diff) |
Added New Junit Cases for APPC Design Services
Issue-ID: APPC-168
Change-Id: Ib321bb77af3cb47abfce80d96f50a6b75b34b34e
Signed-off-by: Anand Chaturvedi <ac204h@att.com>
Diffstat (limited to 'appc-config/appc-data-services/provider/src/test')
-rw-r--r-- | appc-config/appc-data-services/provider/src/test/java/org/openecomp/appc/data/services/db/TestConfigResourceNode.java | 115 |
1 files changed, 115 insertions, 0 deletions
diff --git a/appc-config/appc-data-services/provider/src/test/java/org/openecomp/appc/data/services/db/TestConfigResourceNode.java b/appc-config/appc-data-services/provider/src/test/java/org/openecomp/appc/data/services/db/TestConfigResourceNode.java new file mode 100644 index 000000000..b134de0b1 --- /dev/null +++ b/appc-config/appc-data-services/provider/src/test/java/org/openecomp/appc/data/services/db/TestConfigResourceNode.java @@ -0,0 +1,115 @@ +package org.openecomp.appc.data.services.db;
+
+import java.io.InputStream;
+import java.util.Enumeration;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Properties;
+
+import org.junit.Test;
+import org.openecomp.appc.data.services.AppcDataServiceConstant;
+import org.openecomp.appc.data.services.db.DGGeneralDBService;
+import org.openecomp.appc.data.services.node.ConfigResourceNode;
+import org.apache.commons.lang.StringEscapeUtils;
+import org.junit.After;
+import org.junit.Before;
+import org.openecomp.sdnc.sli.SvcLogicContext;
+import org.openecomp.sdnc.sli.SvcLogicException;
+import org.openecomp.sdnc.sli.SvcLogicResource;
+import org.openecomp.sdnc.sli.SvcLogicResource.QueryStatus;
+import org.openecomp.sdnc.sli.resource.sql.SqlResource;
+import org.apache.commons.io.FileUtils;
+import org.apache.commons.io.IOUtils;
+
+import java.io.File;
+
+public class TestConfigResourceNode {
+
+ @Test(expected = Exception.class)
+ public void testGetUploadConfig1() throws SvcLogicException{
+ SvcLogicContext ctx = new SvcLogicContext();
+ ctx.setAttribute("test","test");
+ ConfigResourceNode dbService = new ConfigResourceNode() ;
+ Map<String,String> map = new HashMap<String,String>();
+ dbService.getConfigFileReference(map,ctx);
+ //System.out.println(status);
+
+
+ }
+
+@Test(expected = Exception.class)
+
+public void testGetUploadConfig2() throws SvcLogicException{
+SvcLogicContext ctx = new SvcLogicContext();
+ctx.setAttribute("test","test");
+ ConfigResourceNode dbService = new ConfigResourceNode() ;
+ Map<String,String> map = new HashMap<String,String>();
+ dbService.getTemplate(map,ctx);
+ //System.out.println(status);
+}
+
+@Test(expected = Exception.class)
+
+public void testGetUploadConfig3() throws SvcLogicException{
+SvcLogicContext ctx = new SvcLogicContext();
+ctx.setAttribute("test","test");
+ ConfigResourceNode dbService = new ConfigResourceNode() ;
+ Map<String,String> map = new HashMap<String,String>();
+ dbService.getVnfcReference(map, ctx);
+ //System.out.println(status);
+
+
+}
+
+@Test(expected = Exception.class)
+
+public void testGetUploadConfig4() throws SvcLogicException{
+SvcLogicContext ctx = new SvcLogicContext();
+ctx.setAttribute("test","test");
+ ConfigResourceNode dbService = new ConfigResourceNode() ;
+ Map<String,String> map = new HashMap<String,String>();
+ dbService.getSmmChainKeyFiles(map, ctx);
+ //System.out.println(status);
+
+
+}
+
+@Test(expected = Exception.class)
+
+public void testGetUploadConfig5() throws SvcLogicException{
+SvcLogicContext ctx = new SvcLogicContext();
+ctx.setAttribute("test","test");
+ ConfigResourceNode dbService = new ConfigResourceNode() ;
+ Map<String,String> map = new HashMap<String,String>();
+ dbService.getDownloadConfigTemplateByVnf(map, ctx);
+ //System.out.println(status);
+
+
+}
+
+@Test(expected = Exception.class)
+public void testGetUploadConfig6() throws SvcLogicException{
+SvcLogicContext ctx = new SvcLogicContext();
+ctx.setAttribute("test","test");
+ ConfigResourceNode dbService = new ConfigResourceNode() ;
+ Map<String,String> map = new HashMap<String,String>();
+ dbService.getCommonConfigInfo(map, ctx);
+ //System.out.println(status);
+
+
+}
+
+@Test(expected = Exception.class)
+public void testGetUploadConfig7() throws SvcLogicException{
+SvcLogicContext ctx = new SvcLogicContext();
+ctx.setAttribute("test","test");
+ ConfigResourceNode dbService = new ConfigResourceNode() ;
+ Map<String,String> map = new HashMap<String,String>();
+ dbService.updateUploadConfig(map, ctx);
+ //System.out.println(status);
+
+
+}
+
+
+}
|