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

kirs pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/incubator-seatunnel.git


The following commit(s) were added to refs/heads/dev by this push:
     new 1351ee9e [Improve][UT] optimize ut logic (#1803)
1351ee9e is described below

commit 1351ee9e292a26b4deda065677c227b998156aae
Author: legendtkl <[email protected]>
AuthorDate: Fri May 6 10:16:47 2022 +0800

    [Improve][UT] optimize ut logic (#1803)
    
    Co-authored-by: taokelu <[email protected]>
---
 .../org/apache/seatunnel/common/config/TypesafeConfigUtilsTest.java  | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git 
a/seatunnel-common/src/test/java/org/apache/seatunnel/common/config/TypesafeConfigUtilsTest.java
 
b/seatunnel-common/src/test/java/org/apache/seatunnel/common/config/TypesafeConfigUtilsTest.java
index 29a778f5..6c672fa0 100644
--- 
a/seatunnel-common/src/test/java/org/apache/seatunnel/common/config/TypesafeConfigUtilsTest.java
+++ 
b/seatunnel-common/src/test/java/org/apache/seatunnel/common/config/TypesafeConfigUtilsTest.java
@@ -20,7 +20,6 @@ package org.apache.seatunnel.common.config;
 import static 
org.apache.seatunnel.common.config.TypesafeConfigUtils.extractSubConfig;
 import static 
org.apache.seatunnel.common.config.TypesafeConfigUtils.extractSubConfigThrowable;
 import static 
org.apache.seatunnel.common.config.TypesafeConfigUtils.hasSubConfig;
-import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertThrows;
 
 import org.apache.seatunnel.shade.com.typesafe.config.Config;
@@ -63,10 +62,10 @@ public class TypesafeConfigUtilsTest {
     @Test
     public void testExtractSubConfigThrowable() {
         Config config = getConfig();
-        Throwable exception = assertThrows(ConfigRuntimeException.class, () -> 
{
+
+        assertThrows("config is empty", ConfigRuntimeException.class, () -> {
             extractSubConfigThrowable(config, "test1.", false);
         });
-        assertEquals("config is empty", exception.getMessage());
 
         Config subConfig = extractSubConfigThrowable(config, "test.", false);
         Map<String, String> configMap = new HashMap<>();

Reply via email to