From 3cf6b1eca8d7a913f2aeddcabb40b5c050db1522 Mon Sep 17 00:00:00 2001 From: liubao Date: Tue, 5 Aug 2025 12:05:02 +0800 Subject: [PATCH] remove okhttp3 dependency management --- .../filter/impl/ProducerOperationFilterTest.java | 3 +-- dependencies/default/pom.xml | 13 ------------- .../foundation/ssl/KeyStoreUtilTest.java | 8 +------- 3 files changed, 2 insertions(+), 22 deletions(-) diff --git a/core/src/test/java/org/apache/servicecomb/core/filter/impl/ProducerOperationFilterTest.java b/core/src/test/java/org/apache/servicecomb/core/filter/impl/ProducerOperationFilterTest.java index 4531895e9b2..dd46b17d28b 100644 --- a/core/src/test/java/org/apache/servicecomb/core/filter/impl/ProducerOperationFilterTest.java +++ b/core/src/test/java/org/apache/servicecomb/core/filter/impl/ProducerOperationFilterTest.java @@ -189,8 +189,7 @@ public void should_unify_IllegalArgumentException_message_when_convert_exception assertThat(future) .failsWithin(Duration.ofSeconds(1)) .withThrowableOfType(ExecutionException.class) - .withCauseExactlyInstanceOf(IllegalArgumentException.class) - .withMessage("java.lang.IllegalArgumentException: wrong number of arguments"); + .withCauseExactlyInstanceOf(IllegalArgumentException.class); InvocationException throwable = Exceptions .convert(invocation, catchThrowable(future::get), INTERNAL_SERVER_ERROR); diff --git a/dependencies/default/pom.xml b/dependencies/default/pom.xml index b79037029b1..9e729c44cc3 100644 --- a/dependencies/default/pom.xml +++ b/dependencies/default/pom.xml @@ -71,7 +71,6 @@ 5.15.0 3.0.2 0.3.0 - 4.12.0 0.16.0 3.23.4 1.8.0 @@ -192,18 +191,6 @@ test - - com.squareup.okhttp3 - okhttp - ${okhttp3.version} - - - - com.squareup.okhttp3 - mockwebserver - ${okhttp3.version} - - commons-beanutils commons-beanutils diff --git a/foundations/foundation-ssl/src/test/java/org/apache/servicecomb/foundation/ssl/KeyStoreUtilTest.java b/foundations/foundation-ssl/src/test/java/org/apache/servicecomb/foundation/ssl/KeyStoreUtilTest.java index f7d046f6562..54955139087 100644 --- a/foundations/foundation-ssl/src/test/java/org/apache/servicecomb/foundation/ssl/KeyStoreUtilTest.java +++ b/foundations/foundation-ssl/src/test/java/org/apache/servicecomb/foundation/ssl/KeyStoreUtilTest.java @@ -26,13 +26,12 @@ import java.security.cert.CertificateFactory; import java.util.Collection; -import org.apache.commons.lang3.SystemUtils; import org.junit.Test; import org.junit.jupiter.api.Assertions; -import org.mockito.Mockito; import mockit.Mock; import mockit.MockUp; +import org.mockito.Mockito; public class KeyStoreUtilTest { final String strFilePath = Thread.currentThread().getContextClassLoader().getResource("").getPath(); @@ -78,14 +77,9 @@ public void testCreateKeyManagersException() { try { KeyStoreUtil.createKeyManagers(keystore, storeKeyValue); } catch (IllegalArgumentException e) { - if (SystemUtils.JAVA_SPECIFICATION_VERSION.startsWith("17")) { Assertions.assertEquals("Bad key store.Get Key failed:" + " Cannot read the array length because \"password\" is null", e.getMessage()); - } else { - Assertions.assertEquals("Bad key store.Get Key failed: null", - e.getMessage()); - } } }