Skip to content

Commit 53d1ba2

Browse files
committed
address review comment
1 parent aa45757 commit 53d1ba2

3 files changed

Lines changed: 3 additions & 29 deletions

File tree

sql/core/src/test/scala/org/apache/spark/sql/streaming/FlatMapGroupsWithStateSuite.scala

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -45,22 +45,13 @@ case class RunningCount(count: Long)
4545

4646
case class Result(key: Long, count: Int)
4747

48-
class FlatMapGroupsWithStateSuite extends StateStoreMetricsTest
49-
with BeforeAndAfterAll {
48+
class FlatMapGroupsWithStateSuite extends StateStoreMetricsTest {
5049

5150
import testImplicits._
5251
import GroupStateImpl._
5352
import GroupStateTimeout._
5453
import FlatMapGroupsWithStateSuite._
5554

56-
override def afterAll(): Unit = {
57-
try {
58-
super.afterAll()
59-
} finally {
60-
StateStore.stop()
61-
}
62-
}
63-
6455
test("GroupState - get, exists, update, remove") {
6556
var state: GroupStateImpl[String] = null
6657

sql/core/src/test/scala/org/apache/spark/sql/streaming/StreamingAggregationSuite.scala

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -46,16 +46,7 @@ object FailureSingleton {
4646
var firstTime = true
4747
}
4848

49-
class StreamingAggregationSuite extends StateStoreMetricsTest
50-
with BeforeAndAfterAll with Assertions {
51-
52-
override def afterAll(): Unit = {
53-
try {
54-
super.afterAll()
55-
} finally {
56-
StateStore.stop()
57-
}
58-
}
49+
class StreamingAggregationSuite extends StateStoreMetricsTest with Assertions {
5950

6051
import testImplicits._
6152

sql/core/src/test/scala/org/apache/spark/sql/streaming/StreamingDeduplicationSuite.scala

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -26,18 +26,10 @@ import org.apache.spark.sql.execution.streaming.state.StateStore
2626
import org.apache.spark.sql.functions._
2727
import org.apache.spark.sql.internal.SQLConf
2828

29-
class StreamingDeduplicationSuite extends StateStoreMetricsTest with BeforeAndAfterAll {
29+
class StreamingDeduplicationSuite extends StateStoreMetricsTest {
3030

3131
import testImplicits._
3232

33-
override def afterAll(): Unit = {
34-
try {
35-
super.afterAll()
36-
} finally {
37-
StateStore.stop()
38-
}
39-
}
40-
4133
test("deduplicate with all columns") {
4234
val inputData = MemoryStream[String]
4335
val result = inputData.toDS().dropDuplicates()

0 commit comments

Comments
 (0)