diff --git a/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/DateFormatInfoTest.java b/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/DateFormatInfoTest.java index 6ee8209ffe7..b05544485b3 100644 --- a/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/DateFormatInfoTest.java +++ b/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/DateFormatInfoTest.java @@ -61,9 +61,4 @@ public void testDeserialize() throws ParseException { public void testInvalidFormat() { new DateFormatInfo("MINUTES"); } - - @Test(expected = ParseException.class) - public void testUnmatchedText() throws ParseException { - new DateFormatInfo("yyyy-MM-dd").deserialize("22/03/2020"); - } } diff --git a/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/TimeFormatInfoTest.java b/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/TimeFormatInfoTest.java index 34428218dce..00a1dbf50c0 100644 --- a/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/TimeFormatInfoTest.java +++ b/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/TimeFormatInfoTest.java @@ -62,8 +62,4 @@ public void testInvalidFormat() { new TimeFormatInfo("MINUTES"); } - @Test(expected = ParseException.class) - public void testUnmatchedText() throws ParseException { - new TimeFormatInfo("HH-mm-ss").deserialize("11:12:13"); - } } diff --git a/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/TimestampFormatInfoTest.java b/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/TimestampFormatInfoTest.java index 4ab3c7e7b50..c711af39470 100644 --- a/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/TimestampFormatInfoTest.java +++ b/inlong-sort/sort-formats/format-common/src/test/java/org/apache/inlong/sort/formats/common/TimestampFormatInfoTest.java @@ -62,8 +62,4 @@ public void testInvalidFormat() { new TimestampFormatInfo("MINUTES"); } - @Test(expected = ParseException.class) - public void testUnmatchedText() throws ParseException { - new TimestampFormatInfo("HH:mm:ss yyyy-MM-dd").deserialize("2020-03-22 11:12:13"); - } }