GitHub user liancheng opened a pull request:

    https://github.com/apache/spark/pull/15802

    [SPARK-18338][SQL] Fix test case initialization order under Maven builds

    ## What changes were proposed in this pull request?
    
    Test case initialization order under Maven and SBT are different. Maven 
always creates instances of all test cases and then run them all together.
    
    This fails `ObjectHashAggregateSuite` because the randomized test cases 
there register a temporary Hive function right before creating a test case, and 
can be cleared while initializing other successive test cases. In SBT, this is 
fine since the created test case is executed immediately after creating the 
temporary function.
    
    To fix this issue, we should put initialization/destruction code into 
`beforeAll()` and `afterAll()`.
    
    ## How was this patch tested?
    
    Existing tests.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/liancheng/spark 
fix-flaky-object-hash-agg-suite

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/15802.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #15802
    
----
commit 7b9a3cb0d1bb943caa9c59c81568dceba7aa2446
Author: Cheng Lian <l...@databricks.com>
Date:   2016-11-07T23:43:49Z

    Fix test case initialization order under Maven builds

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to