rdblue commented on a change in pull request #1240:
URL: https://github.com/apache/iceberg/pull/1240#discussion_r460138461
##########
File path: hive/src/test/java/org/apache/iceberg/hive/HiveTableTest.java
##########
@@ -295,4 +302,29 @@ public void testListTables() {
Assert.assertEquals(1, expectedIdents.size());
Assert.assertTrue(catalog.tableExists(TABLE_IDENTIFIER));
}
+
+ @Test
+ public void testNonDefaultDatabaseLocation() throws IOException, TException {
+ // Create a new location and a non-default database / namespace for it
+ File nonDefaultLocation = createTempDirectory(NON_DEFAULT_DATABASE,
+ asFileAttribute(fromString("rwxrwxrwx"))).toFile();
+ Database database = new Database();
+
+ database.setName(NON_DEFAULT_DATABASE);
+ database.setLocationUri(nonDefaultLocation.getPath());
+ metastoreClient.createDatabase(database);
Review comment:
The catalog supports creating a namespace, so I think this test would be
better if it used the catalog to create the namespace with a location
("location" property) instead of going through the metastore client directly.
Could you update it?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]