Skip to content

Commit

Permalink
Add missing SparkSessionTestWrapper for unsafe
Browse files Browse the repository at this point in the history
  • Loading branch information
zeotuan committed Oct 5, 2024
1 parent dda5ef2 commit 9ea8d77
Showing 1 changed file with 21 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
package org.apache.spark.sql.daria

import org.apache.spark.sql.SparkSession

trait SparkSessionTestWrapper {

lazy val spark: SparkSession = {
val session = SparkSession
.builder()
.master("local")
.appName("spark session")
.config(
"spark.sql.shuffle.partitions",
"1"
)
.getOrCreate()
session.sparkContext.setLogLevel("ERROR")
session
}

}

0 comments on commit 9ea8d77

Please sign in to comment.