diff options
author | Instrumental <jonathan.gathman@att.com> | 2018-08-29 12:47:32 -0500 |
---|---|---|
committer | Instrumental <jonathan.gathman@att.com> | 2018-08-29 14:08:16 -0500 |
commit | af2d592ebbb96d5f5f55f7322f9ecdfdccfce64e (patch) | |
tree | b99bb5ddd7821fd3f0cf202d214eea8208bb4b1e /cadi/client/src/test/java/org/onap | |
parent | 45ca42c48030171a5dcf180bb35fb767ae5c2b78 (diff) |
Change CadiFilter Default SSetter
Issue-ID: AAF-460
Change-Id: I1f7d52104eb36c35cca3264b4995342936e69ef6
Signed-off-by: Instrumental <jonathan.gathman@att.com>
Diffstat (limited to 'cadi/client/src/test/java/org/onap')
-rw-r--r-- | cadi/client/src/test/java/org/onap/aaf/cadi/http/test/JU_HBasicAuthSS.java | 1 | ||||
-rw-r--r-- | cadi/client/src/test/java/org/onap/aaf/cadi/http/test/JU_HX509SS.java | 22 |
2 files changed, 10 insertions, 13 deletions
diff --git a/cadi/client/src/test/java/org/onap/aaf/cadi/http/test/JU_HBasicAuthSS.java b/cadi/client/src/test/java/org/onap/aaf/cadi/http/test/JU_HBasicAuthSS.java index 1b9f6c3a..fa0a673f 100644 --- a/cadi/client/src/test/java/org/onap/aaf/cadi/http/test/JU_HBasicAuthSS.java +++ b/cadi/client/src/test/java/org/onap/aaf/cadi/http/test/JU_HBasicAuthSS.java @@ -35,6 +35,7 @@ import org.onap.aaf.cadi.PropAccess; import org.onap.aaf.cadi.config.Config; import org.onap.aaf.cadi.config.SecurityInfoC; import org.onap.aaf.cadi.http.HBasicAuthSS; +import org.onap.aaf.cadi.http.HSecurityInfoInit; import org.onap.aaf.cadi.principal.BasicPrincipal; public class JU_HBasicAuthSS { diff --git a/cadi/client/src/test/java/org/onap/aaf/cadi/http/test/JU_HX509SS.java b/cadi/client/src/test/java/org/onap/aaf/cadi/http/test/JU_HX509SS.java index 0c086e4b..b57f29e0 100644 --- a/cadi/client/src/test/java/org/onap/aaf/cadi/http/test/JU_HX509SS.java +++ b/cadi/client/src/test/java/org/onap/aaf/cadi/http/test/JU_HX509SS.java @@ -21,6 +21,10 @@ package org.onap.aaf.cadi.http.test; +import static org.hamcrest.CoreMatchers.is; +import static org.junit.Assert.assertThat; +import static org.mockito.Mockito.when; + import java.io.ByteArrayOutputStream; import java.io.IOException; import java.io.PrintStream; @@ -32,12 +36,10 @@ import java.security.cert.X509Certificate; import javax.net.ssl.HttpsURLConnection; import javax.net.ssl.X509KeyManager; -import static org.junit.Assert.*; -import static org.mockito.Mockito.*; -import static org.hamcrest.CoreMatchers.*; - -import org.junit.*; -import org.mockito.*; +import org.junit.Before; +import org.junit.Test; +import org.mockito.Mock; +import org.mockito.MockitoAnnotations; import org.onap.aaf.cadi.CadiException; import org.onap.aaf.cadi.PropAccess; import org.onap.aaf.cadi.config.Config; @@ -75,7 +77,7 @@ public class JU_HX509SS { access = new PropAccess(new PrintStream(new ByteArrayOutputStream()), new String[0]); access.setProperty(Config.CADI_ALIAS, alias); - si = SecurityInfoC.instance(access, HttpURLConnection.class); + // si = SecurityInfoC.instance(access, HttpURLConnectionStub.class); } @Test @@ -106,12 +108,6 @@ public class JU_HX509SS { } @Test(expected = APIException.class) - public void throws2Test() throws APIException, CadiException { - @SuppressWarnings("unused") - HX509SS x509 = new HX509SS(si, false); - } - - @Test(expected = APIException.class) public void throws3Test() throws APIException, CadiException { when(keyManagerMock.getCertificateChain(alias)).thenReturn(new X509Certificate[0]); @SuppressWarnings("unused") |