vaibhawvipul commented on code in PR #384: URL: https://github.com/apache/datafusion-comet/pull/384#discussion_r1594409792
########## spark/src/test/scala/org/apache/comet/CometCastSuite.scala: ########## @@ -960,11 +958,19 @@ class CometCastSuite extends CometTestBase with AdaptiveSparkPlanHelper { val cometMessageModified = cometMessage .replace("[CAST_INVALID_INPUT] ", "") .replace("[CAST_OVERFLOW] ", "") - assert(cometMessageModified == sparkMessage) + .replace("[NUMERIC_VALUE_OUT_OF_RANGE] ", "") + + if (sparkMessage.contains("cannot be represented as")) { + assert(cometMessage.contains("cannot be represented as")) + } else { + assert(cometMessageModified == sparkMessage) + } } else { // for Spark 3.2 we just make sure we are seeing a similar type of error if (sparkMessage.contains("causes overflow")) { assert(cometMessage.contains("due to an overflow")) + } else if (sparkMessage.contains("cannot be represented as")) { + assert(cometMessage.contains("cannot be represented as")) Review Comment: okay, that would be great. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org