diff --git a/sql/catalyst/src/test/scala/org/apache/spark/sql/RandomDataGenerator.scala b/sql/catalyst/src/test/scala/org/apache/spark/sql/RandomDataGenerator.scala index 22f24d8266177..088f0e21710d2 100644 --- a/sql/catalyst/src/test/scala/org/apache/spark/sql/RandomDataGenerator.scala +++ b/sql/catalyst/src/test/scala/org/apache/spark/sql/RandomDataGenerator.scala @@ -53,9 +53,12 @@ object RandomDataGenerator { */ private val PROBABILITY_OF_NULL: Float = 0.1f - final val MAX_STR_LEN: Int = 1024 - final val MAX_ARR_SIZE: Int = 128 - final val MAX_MAP_SIZE: Int = 128 + final val MAX_STR_LEN: Int = + System.getProperty("spark.sql.test.randomDataGenerator.maxStrLen", "1024").toInt + final val MAX_ARR_SIZE: Int = + System.getProperty("spark.sql.test.randomDataGenerator.maxArraySize", "128").toInt + final val MAX_MAP_SIZE: Int = + System.getProperty("spark.sql.test.randomDataGenerator.maxMapSize", "128").toInt /** * Helper function for constructing a biased random number generator which returns "interesting"