From 5ba57e0b76b6d9c7a5d19f75f8bde2a56e13a78f Mon Sep 17 00:00:00 2001 From: Ruifeng Zheng Date: Tue, 21 Apr 2026 07:37:09 +0000 Subject: [PATCH] [SPARK-XXXXX][SQL][TESTS] Use abstract SparkSession in SparkPlanTest Remove the classic SparkSession override from SparkPlanTest, letting it inherit the abstract SparkSession from SparkSessionProvider. Existing ClassicConversions import handles conversions to classic types where needed internally. Co-authored-by: Isaac --- .../scala/org/apache/spark/sql/execution/SparkPlanTest.scala | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sql/core/src/test/scala/org/apache/spark/sql/execution/SparkPlanTest.scala b/sql/core/src/test/scala/org/apache/spark/sql/execution/SparkPlanTest.scala index e9c8b31611085..eae7dfc54a698 100644 --- a/sql/core/src/test/scala/org/apache/spark/sql/execution/SparkPlanTest.scala +++ b/sql/core/src/test/scala/org/apache/spark/sql/execution/SparkPlanTest.scala @@ -20,7 +20,7 @@ package org.apache.spark.sql.execution import scala.util.control.NonFatal import org.apache.spark.SparkFunSuite -import org.apache.spark.sql.{classic, DataFrame, Row, SparkSessionProvider, SQLContext} +import org.apache.spark.sql.{DataFrame, Row, SparkSessionProvider, SQLContext} import org.apache.spark.sql.catalyst.analysis.UnresolvedAttribute import org.apache.spark.sql.catalyst.plans.logical.LocalRelation import org.apache.spark.sql.classic.ClassicConversions._ @@ -31,7 +31,6 @@ import org.apache.spark.sql.test.SQLTestUtils * class's test helper methods can be used, see [[SortSuite]]. */ private[sql] abstract class SparkPlanTest extends SparkFunSuite with SparkSessionProvider { - override protected def spark: classic.SparkSession /** * Runs the plan and makes sure the answer matches the expected result.