You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "tomvanbussel (via GitHub)" <gi...@apache.org> on 2023/01/25 13:21:57 UTC

[GitHub] [spark] tomvanbussel commented on a diff in pull request #39738: [SPARK-42182][CONNECT][TESTS] Make `ReusedConnectTestCase` to take Spark configurations

tomvanbussel commented on code in PR #39738:
URL: https://github.com/apache/spark/pull/39738#discussion_r1086632755


##########
python/pyspark/testing/connectutils.py:
##########
@@ -168,9 +168,21 @@ class ReusedConnectTestCase(unittest.TestCase, SQLTestUtils, PySparkErrorTestUti
     Spark Connect version of :class:`pyspark.testing.sqlutils.ReusedSQLTestCase`.
     """
 
+    @classmethod
+    def conf(cls):
+        """
+        Override this in subclasses to supply a more specific conf
+        """
+        return SparkConf()
+
     @classmethod
     def setUpClass(cls):
-        cls.spark = PySparkSession.builder.appName(cls.__name__).remote("local[4]").getOrCreate()
+        cls.spark = (
+            PySparkSession.builder.config(conf=ReusedConnectTestCase.conf())

Review Comment:
   This currently always uses a new `SparkConf`.
   ```suggestion
               PySparkSession.builder.config(conf=cls.conf())
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org