Skip to content

Commit 251b2c0

Browse files
dongjoon-hyunHyukjinKwon
authored andcommitted
[SPARK-22672][SQL][TEST][FOLLOWUP] Fix to use spark.conf
## What changes were proposed in this pull request? During #19882, `conf` is mistakenly used to switch ORC implementation between `native` and `hive`. To affect `OrcTest` correctly, `spark.conf` should be used. ## How was this patch tested? Pass the tests. Author: Dongjoon Hyun <[email protected]> Closes #19931 from dongjoon-hyun/SPARK-22672-2.
1 parent acf7ef3 commit 251b2c0

File tree

1 file changed

+3
-3
lines changed
  • sql/core/src/test/scala/org/apache/spark/sql/execution/datasources/orc

1 file changed

+3
-3
lines changed

sql/core/src/test/scala/org/apache/spark/sql/execution/datasources/orc/OrcTest.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,12 @@ abstract class OrcTest extends QueryTest with SQLTestUtils with BeforeAndAfterAl
5151

5252
protected override def beforeAll(): Unit = {
5353
super.beforeAll()
54-
originalConfORCImplementation = conf.getConf(ORC_IMPLEMENTATION)
55-
conf.setConf(ORC_IMPLEMENTATION, orcImp)
54+
originalConfORCImplementation = spark.conf.get(ORC_IMPLEMENTATION)
55+
spark.conf.set(ORC_IMPLEMENTATION.key, orcImp)
5656
}
5757

5858
protected override def afterAll(): Unit = {
59-
conf.setConf(ORC_IMPLEMENTATION, originalConfORCImplementation)
59+
spark.conf.set(ORC_IMPLEMENTATION.key, originalConfORCImplementation)
6060
super.afterAll()
6161
}
6262

0 commit comments

Comments
 (0)