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


##########
core/src/test/scala/org/apache/spark/deploy/history/FsHistoryProviderSuite.scala:
##########
@@ -1070,7 +1137,7 @@ class FsHistoryProviderSuite extends SparkFunSuite with 
Matchers with Logging {
     clock.advance(TimeUnit.DAYS.toMillis(2))
     provider.checkForLogs()
     provider.cleanLogs()
-    assert(new File(testDir.toURI).listFiles().size === validLogCount)
+    assert(new File(testDir.toURI).listFiles().length === validLogCount)

Review Comment:
   Sorry, Intellij automatically made code cleanup, and 
[12c0935](https://github.com/apache/spark/pull/36119/commits/12c09357b7f0d1bfc3b70a5f8c2f51d259a055e7)
 and 
[25e2699](https://github.com/apache/spark/pull/36119/commits/25e2699f64668f0bef6fe6c6c23f1097e5186262)
 revert the irrelevant changes
   
   



##########
core/src/test/scala/org/apache/spark/deploy/history/FsHistoryProviderSuite.scala:
##########
@@ -1094,8 +1161,8 @@ class FsHistoryProviderSuite extends SparkFunSuite with 
Matchers with Logging {
     val provider = new FsHistoryProvider(conf)
     updateAndCheck(provider) { list =>
       assert(list.size === 1)
-      assert(list(0).attempts.size === 1)
-      assert(list(0).attempts(0).completed)
+      assert(list.head.attempts.size === 1)
+      assert(list.head.attempts.head.completed)

Review Comment:
   done



##########
core/src/test/scala/org/apache/spark/deploy/history/FsHistoryProviderSuite.scala:
##########
@@ -1249,7 +1316,7 @@ class FsHistoryProviderSuite extends SparkFunSuite with 
Matchers with Logging {
       log3_2.setLastModified(10L)
 
       val provider = new 
FsHistoryProvider(createTestConf().set(MAX_LOG_NUM.key, s"$num"), clock)
-      updateAndCheck(provider) { list =>
+      updateAndCheck(provider) { _ =>

Review Comment:
   done



-- 
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