This is an automated email from the ASF dual-hosted git repository.
reta pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cxf.git
The following commit(s) were added to refs/heads/master by this push:
new 077b0a4ede CXF-8725: Allow RetryStrategy to optionally not retry for
404 responses. Fixing checkstyle violations, minor refactorings and fixes
077b0a4ede is described below
commit 077b0a4ede6fbbe8c7bfb468ea358c7765f12312
Author: Andriy Redko <[email protected]>
AuthorDate: Sun Jun 26 14:27:17 2022 -0400
CXF-8725: Allow RetryStrategy to optionally not retry for 404 responses.
Fixing checkstyle violations, minor refactorings and fixes
---
.../java/org/apache/cxf/message/MessageUtilsTest.java | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
diff --git a/core/src/test/java/org/apache/cxf/message/MessageUtilsTest.java
b/core/src/test/java/org/apache/cxf/message/MessageUtilsTest.java
index 65a09d8935..eec1c94de7 100644
--- a/core/src/test/java/org/apache/cxf/message/MessageUtilsTest.java
+++ b/core/src/test/java/org/apache/cxf/message/MessageUtilsTest.java
@@ -19,7 +19,7 @@
package org.apache.cxf.message;
import java.lang.reflect.Method;
-import java.util.List;
+import java.util.Arrays;
import java.util.Optional;
import javax.xml.namespace.QName;
@@ -30,12 +30,13 @@ import
org.apache.cxf.service.factory.SimpleMethodDispatcher;
import org.apache.cxf.service.invoker.MethodDispatcher;
import org.apache.cxf.service.model.BindingOperationInfo;
import org.apache.cxf.service.model.OperationInfo;
-import org.hamcrest.MatcherAssert;
-import org.hamcrest.Matchers;
+
import org.junit.Test;
+import static org.hamcrest.Matchers.contains;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertThat;
import static org.junit.Assert.assertTrue;
public class MessageUtilsTest {
@@ -86,8 +87,10 @@ public class MessageUtilsTest {
@Test
public void getContextualIntegers() {
Message message = new MessageImpl();
- message.put("key1", "1,2,invalid,3");
- MatcherAssert.assertThat(MessageUtils.getContextualIntegers(message,
"key1", List.of(0)), Matchers.contains(1,2,3));
- MatcherAssert.assertThat(MessageUtils.getContextualIntegers(message,
"invalid-key", List.of(0, 1)), Matchers.contains(0,1));
+ message.put("key1", "1, 2,invalid,3");
+ assertThat(MessageUtils.getContextualIntegers(message, "key1",
Arrays.asList(0)),
+ contains(1, 2, 3));
+ assertThat(MessageUtils.getContextualIntegers(message, "invalid-key",
Arrays.asList(0, 1)),
+ contains(0, 1));
}
}