dongjoon-hyun commented on code in PR #43880:
URL: https://github.com/apache/spark/pull/43880#discussion_r1398474977
##########
sql/core/src/test/scala/org/apache/spark/sql/MathFunctionsSuite.scala:
##########
@@ -262,6 +262,17 @@ class MathFunctionsSuite extends QueryTest with
SharedSparkSession {
}
}
+ test("SPARK-44973: conv must allocate enough space for all digits plus
negative sign") {
+ withSQLConf(SQLConf.ANSI_ENABLED.key -> false.toString) {
+ val df = Seq(
+ ((BigInt(Long.MaxValue) + 1).toString(16)),
+ (BigInt(Long.MinValue).toString(16))
Review Comment:
May I ask what is the target test coverage for this? ` -8000000000000000` is
meaningful?
```
scala> BigInt(Long.MinValue)
res0: scala.math.BigInt = -9223372036854775808
scala> BigInt(Long.MinValue).toString(16)
res1: String = -8000000000000000
```
--
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]