This is an automated email from the ASF dual-hosted git repository.

davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/main by this push:
     new 84f80e51595 chore: Swap assertion test argument to be in correct 
order: expected (#14575)
84f80e51595 is described below

commit 84f80e5159512aff4bba6a24e958dd78528ea5a0
Author: Aurélien Pupier <apup...@redhat.com>
AuthorDate: Tue Jun 18 18:19:33 2024 +0200

    chore: Swap assertion test argument to be in correct order: expected 
(#14575)
    
    value, actual value.
    
    Signed-off-by: Aurélien Pupier <apup...@redhat.com>
---
 .../datalake/component/DataLakeComponentTest.java  |  4 ++--
 .../camel/component/jms/JmsDeliveryDelayTest.java  |  2 +-
 .../http/vertx/VertxPlatformHttpSessionTest.java   |  4 ++--
 .../RestConsumerContextPathMatcherTest.java        | 28 +++++++++++-----------
 .../jbang/core/commands/k/KubeCommandMainTest.java |  2 +-
 5 files changed, 20 insertions(+), 20 deletions(-)

diff --git 
a/components/camel-azure/camel-azure-storage-datalake/src/test/java/org/apache/camel/component/azure/storage/datalake/component/DataLakeComponentTest.java
 
b/components/camel-azure/camel-azure-storage-datalake/src/test/java/org/apache/camel/component/azure/storage/datalake/component/DataLakeComponentTest.java
index d9f6fdc39f7..9c3b90a97ca 100644
--- 
a/components/camel-azure/camel-azure-storage-datalake/src/test/java/org/apache/camel/component/azure/storage/datalake/component/DataLakeComponentTest.java
+++ 
b/components/camel-azure/camel-azure-storage-datalake/src/test/java/org/apache/camel/component/azure/storage/datalake/component/DataLakeComponentTest.java
@@ -78,7 +78,7 @@ class DataLakeComponentTest extends CamelTestSupport {
         assertNull(endpoint.getConfiguration().getServiceClient());
         assertEquals(DataLakeOperationsDefinition.upload, 
endpoint.getConfiguration().getOperation());
         assertEquals("test.txt", endpoint.getConfiguration().getFileName());
-        assertEquals(endpoint.getConfiguration().getCredentialType(), 
CredentialType.AZURE_IDENTITY);
+        assertEquals(CredentialType.AZURE_IDENTITY, 
endpoint.getConfiguration().getCredentialType());
     }
 
     @Test
@@ -93,7 +93,7 @@ class DataLakeComponentTest extends CamelTestSupport {
         assertNull(endpoint.getConfiguration().getServiceClient());
         assertEquals(DataLakeOperationsDefinition.upload, 
endpoint.getConfiguration().getOperation());
         assertEquals("test.txt", endpoint.getConfiguration().getFileName());
-        assertEquals(endpoint.getConfiguration().getCredentialType(), 
CredentialType.AZURE_SAS);
+        assertEquals(CredentialType.AZURE_SAS, 
endpoint.getConfiguration().getCredentialType());
     }
 
     @Test
diff --git 
a/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsDeliveryDelayTest.java
 
b/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsDeliveryDelayTest.java
index a7d4214a6a1..a7576182b76 100644
--- 
a/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsDeliveryDelayTest.java
+++ 
b/components/camel-jms/src/test/java/org/apache/camel/component/jms/JmsDeliveryDelayTest.java
@@ -85,7 +85,7 @@ public class JmsDeliveryDelayTest extends 
AbstractPersistentJMSTest {
         var response = 
template.requestBody("activemq:topic:JmsDeliveryDelayTest2?deliveryDelay=1000", 
"Hello World 2");
 
         MockEndpoint.assertIsSatisfied(context);
-        assertEquals(response, "Hello World 2");
+        assertEquals("Hello World 2", response);
         // give some slack
         assertTrue(routeWatch.taken() >= 900, "Should take at least 1000 
millis");
     }
diff --git 
a/components/camel-platform-http-vertx/src/test/java/org/apache/camel/component/platform/http/vertx/VertxPlatformHttpSessionTest.java
 
b/components/camel-platform-http-vertx/src/test/java/org/apache/camel/component/platform/http/vertx/VertxPlatformHttpSessionTest.java
index 7ef4d3d8862..cb6165cc427 100644
--- 
a/components/camel-platform-http-vertx/src/test/java/org/apache/camel/component/platform/http/vertx/VertxPlatformHttpSessionTest.java
+++ 
b/components/camel-platform-http-vertx/src/test/java/org/apache/camel/component/platform/http/vertx/VertxPlatformHttpSessionTest.java
@@ -189,7 +189,7 @@ public class VertxPlatformHttpSessionTest {
             // 'set-cookie' header for new session, e.g. 
'vertx-web.session=735944d69685aaf63421fb5b3c116b84; Path=/; SameSite=Strict'
             String sessionCookie = getHeader("set-cookie", exchange);
             assertNotNull(getHeader("set-cookie", exchange));
-            assertEquals(getHeader("hitcount", exchange), "1");
+            assertEquals("1", getHeader("hitcount", exchange));
 
             // subsequent call reuses session
             exchange = template.request("direct:session", null);
@@ -197,7 +197,7 @@ public class VertxPlatformHttpSessionTest {
             String cookieHeader = getHeader("cookie", exchange);
             assertEquals(cookieHeader, sessionCookie.substring(0, 
sessionCookie.indexOf(';')));
             assertNull(getHeader("set-cookie", exchange));
-            assertEquals(getHeader("hitcount", exchange), "2");
+            assertEquals("2", getHeader("hitcount", exchange));
 
         } finally {
             context.stop();
diff --git 
a/core/camel-support/src/test/java/org/apache/camel/support/RestConsumerContextPathMatcherTest.java
 
b/core/camel-support/src/test/java/org/apache/camel/support/RestConsumerContextPathMatcherTest.java
index 069a177eebc..f3af3276784 100644
--- 
a/core/camel-support/src/test/java/org/apache/camel/support/RestConsumerContextPathMatcherTest.java
+++ 
b/core/camel-support/src/test/java/org/apache/camel/support/RestConsumerContextPathMatcherTest.java
@@ -83,7 +83,7 @@ public class RestConsumerContextPathMatcherTest {
 
         RestConsumerContextPathMatcher.ConsumerPath<?> path = 
RestConsumerContextPathMatcher.matchBestPath("GET",
                 "/camel/a/b/3", consumerPaths);
-        assertEquals(path.getConsumerPath(), "/camel/a/b/{c}");
+        assertEquals("/camel/a/b/{c}", path.getConsumerPath());
     }
 
     @ParameterizedTest
@@ -130,9 +130,9 @@ public class RestConsumerContextPathMatcherTest {
         RestConsumerContextPathMatcher.ConsumerPath<?> path3 = 
RestConsumerContextPathMatcher.matchBestPath("GET",
                 "/camel/myapp/order/foo", consumerPaths);
 
-        assertEquals(path1.getConsumerPath(), "/camel/myapp/info");
-        assertEquals(path2.getConsumerPath(), "/camel/myapp/{id}");
-        assertEquals(path3.getConsumerPath(), "/camel/myapp/order/*");
+        assertEquals("/camel/myapp/info", path1.getConsumerPath());
+        assertEquals("/camel/myapp/{id}", path2.getConsumerPath());
+        assertEquals("/camel/myapp/order/*", path3.getConsumerPath());
     }
 
     @Test
@@ -153,9 +153,9 @@ public class RestConsumerContextPathMatcherTest {
         RestConsumerContextPathMatcher.ConsumerPath<?> path3 = 
RestConsumerContextPathMatcher.matchBestPath("GET",
                 "/camel/foo/bar/1", consumerPaths);
 
-        assertEquals(path1.getConsumerPath(), "/camel/foo");
-        assertEquals(path2.getConsumerPath(), "/camel/foo/{id}");
-        assertEquals(path3.getConsumerPath(), "/camel/*");
+        assertEquals("/camel/foo", path1.getConsumerPath());
+        assertEquals("/camel/foo/{id}", path2.getConsumerPath());
+        assertEquals("/camel/*", path3.getConsumerPath());
     }
 
     @Test
@@ -169,38 +169,38 @@ public class RestConsumerContextPathMatcherTest {
         assertNull(path1);
         RestConsumerContextPathMatcher.ConsumerPath<?> path2 = 
RestConsumerContextPathMatcher.matchBestPath("POST",
                 "/pet", consumerPaths);
-        assertEquals(path2.getConsumerPath(), "/pet");
+        assertEquals("/pet", path2.getConsumerPath());
 
         RestConsumerContextPathMatcher.ConsumerPath<?> path3 = 
RestConsumerContextPathMatcher.matchBestPath("GET",
                 "/pet/findByStatus", consumerPaths);
-        assertEquals(path3.getConsumerPath(), "/pet/findByStatus");
+        assertEquals("/pet/findByStatus", path3.getConsumerPath());
         RestConsumerContextPathMatcher.ConsumerPath<?> path4 = 
RestConsumerContextPathMatcher.matchBestPath("DELETE",
                 "/pet/findByStatus", consumerPaths);
         assertNull(path4);
 
         RestConsumerContextPathMatcher.ConsumerPath<?> path5 = 
RestConsumerContextPathMatcher.matchBestPath("GET",
                 "/pet/findByTags", consumerPaths);
-        assertEquals(path5.getConsumerPath(), "/pet/findByTags");
+        assertEquals("/pet/findByTags", path5.getConsumerPath());
         RestConsumerContextPathMatcher.ConsumerPath<?> path6 = 
RestConsumerContextPathMatcher.matchBestPath("POST",
                 "/pet/findByStatus", consumerPaths);
         assertNull(path6);
 
         RestConsumerContextPathMatcher.ConsumerPath<?> path7 = 
RestConsumerContextPathMatcher.matchBestPath("GET",
                 "/pet/123", consumerPaths);
-        assertEquals(path7.getConsumerPath(), "/pet/{petId}");
+        assertEquals("/pet/{petId}", path7.getConsumerPath());
         RestConsumerContextPathMatcher.ConsumerPath<?> path8 = 
RestConsumerContextPathMatcher.matchBestPath("POST",
                 "/pet/222", consumerPaths);
-        assertEquals(path8.getConsumerPath(), "/pet/{petId}");
+        assertEquals("/pet/{petId}", path8.getConsumerPath());
         RestConsumerContextPathMatcher.ConsumerPath<?> path9 = 
RestConsumerContextPathMatcher.matchBestPath("DELETE",
                 "/pet/333", consumerPaths);
-        assertEquals(path9.getConsumerPath(), "/pet/{petId}");
+        assertEquals("/pet/{petId}", path9.getConsumerPath());
         RestConsumerContextPathMatcher.ConsumerPath<?> path10 = 
RestConsumerContextPathMatcher.matchBestPath("PUT",
                 "/pet/444", consumerPaths);
         assertNull(path10);
 
         RestConsumerContextPathMatcher.ConsumerPath<?> path11 = 
RestConsumerContextPathMatcher.matchBestPath("POST",
                 "/pet/123/uploadImage", consumerPaths);
-        assertEquals(path11.getConsumerPath(), "/pet/{petId}/uploadImage");
+        assertEquals("/pet/{petId}/uploadImage", path11.getConsumerPath());
         RestConsumerContextPathMatcher.ConsumerPath<?> path12 = 
RestConsumerContextPathMatcher.matchBestPath("DELETE",
                 "/pet/222/uploadImage", consumerPaths);
         assertNull(path12);
diff --git 
a/dsl/camel-jbang/camel-jbang-plugin-k/src/test/java/org/apache/camel/dsl/jbang/core/commands/k/KubeCommandMainTest.java
 
b/dsl/camel-jbang/camel-jbang-plugin-k/src/test/java/org/apache/camel/dsl/jbang/core/commands/k/KubeCommandMainTest.java
index 7cf10191c45..1edd316d02f 100644
--- 
a/dsl/camel-jbang/camel-jbang-plugin-k/src/test/java/org/apache/camel/dsl/jbang/core/commands/k/KubeCommandMainTest.java
+++ 
b/dsl/camel-jbang/camel-jbang-plugin-k/src/test/java/org/apache/camel/dsl/jbang/core/commands/k/KubeCommandMainTest.java
@@ -82,7 +82,7 @@ class KubeCommandMainTest extends KubeBaseTest {
 
         Integration integration = 
kubernetesClient.resources(Integration.class).withName("route").get();
         Assertions.assertNotNull(integration);
-        
Assertions.assertEquals(integration.getMetadata().getAnnotations().get(KubeCommand.OPERATOR_ID_LABEL),
 "camel-k");
+        Assertions.assertEquals("camel-k", 
integration.getMetadata().getAnnotations().get(KubeCommand.OPERATOR_ID_LABEL));
     }
 
     @Test

Reply via email to