File tree Expand file tree Collapse file tree 2 files changed +7
-9
lines changed
core/src/test/scala/org/apache/spark/sql
hive/src/test/scala/org/apache/spark/sql/hive Expand file tree Collapse file tree 2 files changed +7
-9
lines changed Original file line number Diff line number Diff line change @@ -44,6 +44,12 @@ class SessionStateSuite extends SparkFunSuite
4444 createSession()
4545 }
4646
47+ override def afterAll (): Unit = {
48+ if (sparkContext != null ) {
49+ sparkContext.stop()
50+ }
51+ }
52+
4753 test(" fork new session and inherit RuntimeConfig options" ) {
4854 val key = " spark-config-clone"
4955 activeSession.conf.set(key, " active" )
Original file line number Diff line number Diff line change @@ -28,20 +28,12 @@ import org.apache.spark.sql.hive.test.TestHiveSingleton
2828class HiveSessionStateSuite extends SessionStateSuite
2929 with TestHiveSingleton with BeforeAndAfterEach {
3030
31- override def beforeEach (): Unit = {
32- createSession()
33- }
34-
3531 override def afterEach (): Unit = {}
3632
3733 override def beforeAll (): Unit = {}
3834
3935 override def afterAll (): Unit = {
40- try {
41- hiveContext.reset()
42- } finally {
43- super .afterAll()
44- }
36+ hiveContext.reset()
4537 }
4638
4739 override def createSession (): Unit = {
You can’t perform that action at this time.
0 commit comments