gh-yzou commented on code in PR #1349:
URL: https://github.com/apache/polaris/pull/1349#discussion_r2043261136


##########
plugins/spark/v3.5/integration/src/intTest/java/org/apache/polaris/spark/quarkus/it/SparkCatalogOperationsIT.java:
##########
@@ -0,0 +1,250 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.polaris.spark.quarkus.it;
+
+import static org.assertj.core.api.Assertions.assertThat;
+import static org.assertj.core.api.Assertions.assertThatThrownBy;
+
+import com.google.common.collect.Maps;
+import io.quarkus.test.junit.QuarkusIntegrationTest;
+import java.util.Arrays;
+import java.util.Map;
+import org.apache.iceberg.exceptions.BadRequestException;
+import org.apache.polaris.spark.SparkCatalog;
+import org.apache.spark.sql.catalyst.analysis.NoSuchNamespaceException;
+import org.apache.spark.sql.catalyst.analysis.NoSuchViewException;
+import org.apache.spark.sql.connector.catalog.Identifier;
+import org.apache.spark.sql.connector.catalog.NamespaceChange;
+import org.apache.spark.sql.connector.catalog.View;
+import org.apache.spark.sql.connector.catalog.ViewChange;
+import org.apache.spark.sql.types.StructType;
+import org.junit.jupiter.api.Test;
+
+@QuarkusIntegrationTest
+public class SparkCatalogOperationsIT extends SparkIntegrationBase {
+  /**
+   * This integration directly performs operations using the SparkCatalog 
instance, instead of going
+   * through Spark SQL interface. Some operations don't have an easy way to 
trigger through the
+   * SparkSQL, for example, list nested namespaces.
+   */
+  private static StructType schema = new StructType().add("id", 
"long").add("name", "string");
+
+  @Test
+  void testNamespaceOperations() throws Exception {
+    SparkCatalog catalog = loadSparkCatalog();

Review Comment:
   I see, make sense. I updated the test to have a SparkCatalogBaseIT to have 
tests that works for both iceberg and polaris, and SparkCatalogIcebergIT and 
SparkCatalogPolarisIT that extends the baseIT with 
org.apache.iceberg.spark.SparkCatalog and org.apache.polaris.spark.SparkCatalog 
separately



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to