tgravescs commented on a change in pull request #30504: URL: https://github.com/apache/spark/pull/30504#discussion_r533648996
########## File path: sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/optimizer/ConstantFoldingSuite.scala ########## @@ -263,4 +263,19 @@ class ConstantFoldingSuite extends PlanTest { comparePlans(optimized, correctAnswer) } + + test("Constant folding test with sideaffects") { + val originalQuery = + testRelation + .select("size(array(assert_true(false)))") + + val optimized = Optimize.execute(originalQuery.analyze) + + val correctAnswer = + testRelation + .select("size(array(assert_true(false)))") + .analyze + + comparePlans(optimized, correctAnswer) Review comment: those were covered in the other test, but I can add another one here as well ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org