You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "LuciferYang (via GitHub)" <gi...@apache.org> on 2023/10/01 15:06:12 UTC

[GitHub] [spark] LuciferYang commented on a diff in pull request #43194: [SPARK-45283][CORE][TESTS] Make StatusTrackerSuite less fragile

LuciferYang commented on code in PR #43194:
URL: https://github.com/apache/spark/pull/43194#discussion_r1342148839


##########
core/src/test/scala/org/apache/spark/StatusTrackerSuite.scala:
##########
@@ -33,7 +33,7 @@ class StatusTrackerSuite extends SparkFunSuite with Matchers with LocalSparkCont
     val jobId: Int = eventually(timeout(10.seconds)) {
       val jobIds = jobFuture.jobIds
       jobIds.size should be(1)
-      jobIds.head
+      jobIds.sorted.reverse.head

Review Comment:
   If the goal is to get the largest JobId, can we use `jobIds.max`? 



-- 
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: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org