maropu commented on a change in pull request #28173: [SPARK-31389][SQL][TESTS] 
Ensure all tests in SQLMetricsSuite run with both codegen on and off
URL: https://github.com/apache/spark/pull/28173#discussion_r409935155
 
 

 ##########
 File path: 
sql/core/src/test/scala/org/apache/spark/sql/execution/metric/SQLMetricsSuite.scala
 ##########
 @@ -82,11 +82,14 @@ class SQLMetricsSuite extends SharedSparkSession with 
SQLMetricsTestUtils {
   test("Filter metrics") {
     // Assume the execution plan is
     // PhysicalRDD(nodeId = 1) -> Filter(nodeId = 0)
-    val df = person.filter('age < 25)
-    testSparkPlanMetrics(df, 1, Map(
-      0L -> (("Filter", Map(
-        "number of output rows" -> 1L))))
-    )
+    Seq((0L, false), (1L, true)).foreach { args =>
 
 Review comment:
   For better readability, could you use named variables, e.g., `.foreach { 
case (xxx, yyy) =>`?

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


With regards,
Apache Git Services

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

Reply via email to