wangyum commented on a change in pull request #34580:
URL: https://github.com/apache/spark/pull/34580#discussion_r749828937



##########
File path: 
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/optimizer/SimplifyConditionalsInPredicateSuite.scala
##########
@@ -222,7 +225,7 @@ class SimplifyConditionalsInPredicateSuite extends PlanTest 
{
   }
 
   private def testProjection(originalExpr: Expression, expectedExpr: 
Expression): Unit = {
-    test((rel, exp) => rel.select(exp), originalExpr, expectedExpr)
+    test((rel, exp) => rel.select(exp), originalExpr.as("out"), 
expectedExpr.as("out"))

Review comment:
       Add alias to avoid test failure:
   ```
   == FAIL: Plans do not match ===
   !Project [CASE WHEN (i#0 > 10) THEN b#0 END AS CASE WHEN (i > 10) THEN b 
ELSE NULL END#0]   Project [CASE WHEN (i#0 > 10) THEN b#0 END AS CASE WHEN (i > 
10) THEN b END#0]
    +- LocalRelation <empty>, [i#0, b#0, a#0, m#0]                              
               +- LocalRelation <empty>, [i#0, b#0, a#0, m#0]
   
   ```




-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to