Repository: spark Updated Branches: refs/heads/branch-2.4 4099565cd -> d5e694805
[SPARK-25805][SQL][TEST] Fix test for SPARK-25159 The original test would sometimes fail if the listener bus did not keep up, so just wait till the listener bus is empty. Tested by adding a sleep in the listener, which made the test consistently fail without the fix, but pass consistently after the fix. Closes #22799 from squito/SPARK-25805. Authored-by: Imran Rashid <[email protected]> Signed-off-by: Wenchen Fan <[email protected]> (cherry picked from commit 78c8bd2e68a77ee3c12c233289a8804e339bd71d) Signed-off-by: Wenchen Fan <[email protected]> Project: http://git-wip-us.apache.org/repos/asf/spark/repo Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/d5e69480 Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/d5e69480 Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/d5e69480 Branch: refs/heads/branch-2.4 Commit: d5e694805033781ffd161d63ddc4e73bf62d389a Parents: 4099565 Author: Imran Rashid <[email protected]> Authored: Tue Oct 23 14:20:29 2018 +0800 Committer: Wenchen Fan <[email protected]> Committed: Tue Oct 23 14:20:55 2018 +0800 ---------------------------------------------------------------------- sql/core/src/test/scala/org/apache/spark/sql/DataFrameSuite.scala | 1 + 1 file changed, 1 insertion(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/spark/blob/d5e69480/sql/core/src/test/scala/org/apache/spark/sql/DataFrameSuite.scala ---------------------------------------------------------------------- diff --git a/sql/core/src/test/scala/org/apache/spark/sql/DataFrameSuite.scala b/sql/core/src/test/scala/org/apache/spark/sql/DataFrameSuite.scala index 4a7bd2f..e84cd8c 100644 --- a/sql/core/src/test/scala/org/apache/spark/sql/DataFrameSuite.scala +++ b/sql/core/src/test/scala/org/apache/spark/sql/DataFrameSuite.scala @@ -2549,6 +2549,7 @@ class DataFrameSuite extends QueryTest with SharedSQLContext { val df = spark.read.json(path.getCanonicalPath) assert(df.columns === Array("i", "p")) + spark.sparkContext.listenerBus.waitUntilEmpty(10000) assert(numJobs == 1) } } --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
