spark-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sro...@apache.org
Subject spark git commit: [SPARK-25605][TESTS] Alternate take. Run cast string to timestamp tests for a subset of timezones
Date Wed, 10 Oct 2018 15:25:15 GMT
Repository: spark
Updated Branches:
  refs/heads/master 3caab872d -> eaafcd8a2


[SPARK-25605][TESTS] Alternate take. Run cast string to timestamp tests for a subset of timezones

## What changes were proposed in this pull request?

Try testing timezones in parallel instead in CastSuite, instead of random sampling.
See also #22631

## How was this patch tested?

Existing test.

Closes #22672 from srowen/SPARK-25605.2.

Authored-by: Sean Owen <sean.owen@databricks.com>
Signed-off-by: Sean Owen <sean.owen@databricks.com>


Project: http://git-wip-us.apache.org/repos/asf/spark/repo
Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/eaafcd8a
Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/eaafcd8a
Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/eaafcd8a

Branch: refs/heads/master
Commit: eaafcd8a22db187e87f09966826dcf677c4c38ea
Parents: 3caab87
Author: Sean Owen <sean.owen@databricks.com>
Authored: Wed Oct 10 08:25:12 2018 -0700
Committer: Sean Owen <sean.owen@databricks.com>
Committed: Wed Oct 10 08:25:12 2018 -0700

----------------------------------------------------------------------
 .../org/apache/spark/sql/catalyst/expressions/CastSuite.scala      | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/spark/blob/eaafcd8a/sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/CastSuite.scala
----------------------------------------------------------------------
diff --git a/sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/CastSuite.scala
b/sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/CastSuite.scala
index 90c0bf7..94dee7e 100644
--- a/sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/CastSuite.scala
+++ b/sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/CastSuite.scala
@@ -112,7 +112,7 @@ class CastSuite extends SparkFunSuite with ExpressionEvalHelper {
   }
 
   test("cast string to timestamp") {
-    for (tz <- Random.shuffle(ALL_TIMEZONES).take(50)) {
+    ALL_TIMEZONES.par.foreach { tz =>
       def checkCastStringToTimestamp(str: String, expected: Timestamp): Unit = {
         checkEvaluation(cast(Literal(str), TimestampType, Option(tz.getID)), expected)
       }


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


Mime
View raw message