nastra commented on code in PR #9877:
URL: https://github.com/apache/iceberg/pull/9877#discussion_r1514142672


##########
nessie/src/test/java/org/apache/iceberg/nessie/TestNamespace.java:
##########
@@ -132,6 +133,15 @@ public void testSettingProperties() {
         .hasMessage("Namespace does not exist: unknown");
   }
 
+  @Test
+  public void testEmptyNamespace() {
+    Assertions.assertThatThrownBy(
+            () -> catalog.createNamespace(Namespace.empty(), 
Collections.emptyMap()))
+        .isInstanceOf(IllegalArgumentException.class)
+        .hasMessage("Creating empty namespaces is not supported");
+    
Assertions.assertThat(catalog.namespaceExists(Namespace.empty())).isFalse();

Review Comment:
   I would also add a check that uses `loadNamespaceMetadata()` directly with 
an empty namespace



-- 
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: issues-unsubscr...@iceberg.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org
For additional commands, e-mail: issues-h...@iceberg.apache.org

Reply via email to