You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by sk...@apache.org on 2022/01/21 08:32:50 UTC

[ignite-3] branch main updated: IGNITE-16286 Fixed error message. Fixes #547

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

sk0x50 pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/ignite-3.git


The following commit(s) were added to refs/heads/main by this push:
     new 1728cd1  IGNITE-16286 Fixed error message. Fixes #547
1728cd1 is described below

commit 1728cd12a3a20880c2a80d730f0412b9827bfecb
Author: Slava Koptilin <sl...@gmail.com>
AuthorDate: Fri Jan 21 11:32:31 2022 +0300

    IGNITE-16286 Fixed error message. Fixes #547
---
 .../src/test/java/org/apache/ignite/client/ConnectionTest.java     | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/modules/client/src/test/java/org/apache/ignite/client/ConnectionTest.java b/modules/client/src/test/java/org/apache/ignite/client/ConnectionTest.java
index a7c5c63..fe404df 100644
--- a/modules/client/src/test/java/org/apache/ignite/client/ConnectionTest.java
+++ b/modules/client/src/test/java/org/apache/ignite/client/ConnectionTest.java
@@ -19,6 +19,7 @@ package org.apache.ignite.client;
 
 import static org.junit.jupiter.api.Assertions.assertEquals;
 import static org.junit.jupiter.api.Assertions.assertThrows;
+import static org.junit.jupiter.api.Assertions.assertTrue;
 
 import org.apache.ignite.lang.IgniteException;
 import org.junit.jupiter.api.Disabled;
@@ -50,7 +51,11 @@ public class ConnectionTest extends AbstractClientTest {
         var ex = assertThrows(IgniteClientConnectionException.class,
                 () -> testConnection("127.0.0.1:47500"));
 
-        assertEquals("Connection refused: /127.0.0.1:47500", ex.getCause().getMessage());
+        String errMsg = ex.getCause().getMessage();
+
+        assertTrue(
+                errMsg.startsWith("Connection refused"),
+                "Error message should start with 'Connection refused' [actual=" + errMsg + ']');
     }
 
     @Test