You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by mi...@apache.org on 2020/01/12 12:03:19 UTC
[httpcomponents-core] branch 4.4.x updated: HTTPCORE-622:
TestJSSEProviderIntegration fails if Conscrypt JNI wrapper cannot be loaded
This is an automated email from the ASF dual-hosted git repository.
michaelo pushed a commit to branch 4.4.x
in repository https://gitbox.apache.org/repos/asf/httpcomponents-core.git
The following commit(s) were added to refs/heads/4.4.x by this push:
new 97b30f3 HTTPCORE-622: TestJSSEProviderIntegration fails if Conscrypt JNI wrapper cannot be loaded
97b30f3 is described below
commit 97b30f385052f520a18b66faff2af7e84247e2ce
Author: Michael Osipov <mi...@apache.org>
AuthorDate: Fri Jan 3 11:31:16 2020 +0100
HTTPCORE-622: TestJSSEProviderIntegration fails if Conscrypt JNI wrapper cannot be loaded
---
.../apache/http/nio/integration/TestJSSEProviderIntegration.java | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/httpcore-nio/src/test/java/org/apache/http/nio/integration/TestJSSEProviderIntegration.java b/httpcore-nio/src/test/java/org/apache/http/nio/integration/TestJSSEProviderIntegration.java
index 346abe4..3bac7c1 100644
--- a/httpcore-nio/src/test/java/org/apache/http/nio/integration/TestJSSEProviderIntegration.java
+++ b/httpcore-nio/src/test/java/org/apache/http/nio/integration/TestJSSEProviderIntegration.java
@@ -112,7 +112,11 @@ public class TestJSSEProviderIntegration {
@Override
protected void before() throws Throwable {
if ("Conscrypt".equalsIgnoreCase(securityProviderName)) {
- securityProvider = Conscrypt.newProviderBuilder().provideTrustManager(true).build();
+ try {
+ securityProvider = Conscrypt.newProviderBuilder().provideTrustManager(true).build();
+ } catch (final UnsatisfiedLinkError e) {
+ Assume.assumeFalse("Conscrypt provider failed to be loaded: " + e.getMessage(), true);
+ }
} else {
securityProvider = null;
}