summaryrefslogtreecommitdiffstats
path: root/huawei/vnfmadapter/VnfmadapterService
diff options
context:
space:
mode:
authorWeitao Gao <victor.gao@huawei.com>2020-08-24 13:09:00 +0000
committerGerrit Code Review <gerrit@onap.org>2020-08-24 13:09:00 +0000
commitf5b1fff8d73e136a1c46f61fe43cc454d26522b5 (patch)
tree102a3f664b26cb7f6a4bc01bab5add4322cde887 /huawei/vnfmadapter/VnfmadapterService
parent2b39fc622f37c88e7b328476414dc90e1146b8ec (diff)
parent78d42adbd94c1a14d590678b7c7bd270a3e96b9e (diff)
Merge "Code coverage should be at least 55% (SslProtocolSocketFactory class) Issue-ID: VFC-1726"
Diffstat (limited to 'huawei/vnfmadapter/VnfmadapterService')
-rw-r--r--huawei/vnfmadapter/VnfmadapterService/service/src/test/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/service/csm/connect/SslProtocolSocketFactoryTest.java16
1 files changed, 14 insertions, 2 deletions
diff --git a/huawei/vnfmadapter/VnfmadapterService/service/src/test/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/service/csm/connect/SslProtocolSocketFactoryTest.java b/huawei/vnfmadapter/VnfmadapterService/service/src/test/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/service/csm/connect/SslProtocolSocketFactoryTest.java
index 27236ca7..bd701206 100644
--- a/huawei/vnfmadapter/VnfmadapterService/service/src/test/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/service/csm/connect/SslProtocolSocketFactoryTest.java
+++ b/huawei/vnfmadapter/VnfmadapterService/service/src/test/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/service/csm/connect/SslProtocolSocketFactoryTest.java
@@ -16,12 +16,12 @@
package org.onap.vfc.nfvo.vnfm.svnfm.vnfmadapter.service.csm.connect;
-import static org.junit.Assert.*;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
import org.apache.commons.httpclient.protocol.ProtocolSocketFactory;
import org.junit.Test;
import org.onap.vfc.nfvo.vnfm.svnfm.vnfmadapter.common.VnfmException;
-import org.onap.vfc.nfvo.vnfm.svnfm.vnfmadapter.service.csm.connect.SslProtocolSocketFactory;
public class SslProtocolSocketFactoryTest {
@@ -45,4 +45,16 @@ public class SslProtocolSocketFactoryTest {
SslProtocolSocketFactory.getInstance().refresh("Anonymous");
assertTrue(true);
}
+ @Test
+ public void getAnonymousTest() throws VnfmException{
+ String authenticateMode="Anonymous";
+ SslProtocolSocketFactory.getInstance().get(authenticateMode);
+ assertTrue(true);
+ }
+ @Test
+ public void getCertificateTest() throws VnfmException{
+ String authenticateMode="Certificate";
+ SslProtocolSocketFactory.getInstance().get(authenticateMode);
+ assertTrue(true);
+ }
}