From a655831756188a8c3777a4b9e953a2640c53aaab Mon Sep 17 00:00:00 2001 From: zhli Date: Tue, 5 Dec 2023 14:15:12 +0800 Subject: [PATCH] fix ut --- .../org/apache/spark/sql/gluten/GlutenFallbackSuite.scala | 8 +++----- .../org/apache/spark/sql/gluten/GlutenFallbackSuite.scala | 8 +++----- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/gluten-ut/spark33/src/test/scala/org/apache/spark/sql/gluten/GlutenFallbackSuite.scala b/gluten-ut/spark33/src/test/scala/org/apache/spark/sql/gluten/GlutenFallbackSuite.scala index 8a2acc9db1e6..3799e494ab4e 100644 --- a/gluten-ut/spark33/src/test/scala/org/apache/spark/sql/gluten/GlutenFallbackSuite.scala +++ b/gluten-ut/spark33/src/test/scala/org/apache/spark/sql/gluten/GlutenFallbackSuite.scala @@ -36,11 +36,9 @@ class GlutenFallbackSuite extends GlutenSQLTestsTrait { sql("SELECT * FROM t").collect() } } - assert( - testAppender.loggingEvents.exists( - _.getMessage.getFormattedMessage.contains( - "Validation failed for plan: Scan parquet default.t, " + - "due to: columnar FileScan is not enabled in FileSourceScanExec"))) + val msgRegex = """Validation failed for plan: Scan parquet default\.t\[QueryId=[0-9]+\],""" + + """ due to: columnar FileScan is not enabled in FileSourceScanExec\.""" + assert(testAppender.loggingEvents.exists(_.getMessage.getFormattedMessage.matches(msgRegex))) } } diff --git a/gluten-ut/spark34/src/test/scala/org/apache/spark/sql/gluten/GlutenFallbackSuite.scala b/gluten-ut/spark34/src/test/scala/org/apache/spark/sql/gluten/GlutenFallbackSuite.scala index 44e848a31e7c..62fbedd04771 100644 --- a/gluten-ut/spark34/src/test/scala/org/apache/spark/sql/gluten/GlutenFallbackSuite.scala +++ b/gluten-ut/spark34/src/test/scala/org/apache/spark/sql/gluten/GlutenFallbackSuite.scala @@ -36,11 +36,9 @@ class GlutenFallbackSuite extends GlutenSQLTestsTrait { sql("SELECT * FROM t").collect() } } - assert( - testAppender.loggingEvents.exists( - _.getMessage.getFormattedMessage.contains( - "Validation failed for plan: Scan parquet default.t, " + - "due to: columnar FileScan is not enabled in FileSourceScanExec"))) + val msgRegex = """Validation failed for plan: Scan parquet default\.t\[QueryId=[0-9]+\],""" + + """ due to: columnar FileScan is not enabled in FileSourceScanExec\.""" + assert(testAppender.loggingEvents.exists(_.getMessage.getFormattedMessage.matches(msgRegex))) } }