cloud-fan commented on a change in pull request #27494: [SPARK-30760][SQL] Port 
`millisToDays` and `daysToMillis` on Java 8 time API
URL: https://github.com/apache/spark/pull/27494#discussion_r376974086
 
 

 ##########
 File path: 
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/DateExpressionsSuite.scala
 ##########
 @@ -494,7 +494,7 @@ class DateExpressionsSuite extends SparkFunSuite with 
ExpressionEvalHelper {
     // Valid range of DateType is [0001-01-01, 9999-12-31]
     val maxMonthInterval = 10000 * 12
     checkEvaluation(
-      AddMonths(Literal(Date.valueOf("0001-01-01")), 
Literal(maxMonthInterval)), 2933261)
+      AddMonths(Literal(LocalDate.parse("0001-01-01")), 
Literal(maxMonthInterval)), 2933263)
 
 Review comment:
   can we place the hardcoded `2933263` with `LocalDate.of(10001, 1, 
1).toEpochDay`?

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