You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spark.apache.org by gu...@apache.org on 2019/03/09 00:12:50 UTC

[spark] branch master updated: [SPARK-27101][PYTHON] Drop the created database after the test in test_session

This is an automated email from the ASF dual-hosted git repository.

gurwls223 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/spark.git


The following commit(s) were added to refs/heads/master by this push:
     new 14f2286  [SPARK-27101][PYTHON] Drop the created database after the test in test_session
14f2286 is described below

commit 14f2286e563c400881c00673fe8ceea99142497b
Author: sandeep-katta <sa...@gmail.com>
AuthorDate: Sat Mar 9 09:12:33 2019 +0900

    [SPARK-27101][PYTHON] Drop the created database after the test in test_session
    
    ## What changes were proposed in this pull request?
    
    Cleaning the testcase, drop the database after use
    
    ## How was this patch tested?
    
    existing UT
    
    Closes #24021 from sandeep-katta/cleanPythonTest.
    
    Authored-by: sandeep-katta <sa...@gmail.com>
    Signed-off-by: Hyukjin Kwon <gu...@apache.org>
---
 python/pyspark/sql/tests/test_session.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/python/pyspark/sql/tests/test_session.py b/python/pyspark/sql/tests/test_session.py
index c6b9e0b..518fad4 100644
--- a/python/pyspark/sql/tests/test_session.py
+++ b/python/pyspark/sql/tests/test_session.py
@@ -114,6 +114,7 @@ class SparkSessionTests3(unittest.TestCase):
             self.assertEqual(spark.table("table1").columns, ['name', 'age'])
             self.assertEqual(spark.range(3).count(), 3)
         finally:
+            spark.sql("DROP DATABASE test_db CASCADE")
             spark.stop()
 
     def test_global_default_session(self):


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