Skip to content

Commit

Permalink
[#3783] improvement(test): add test 'list-all-tables' for the Hive ca…
Browse files Browse the repository at this point in the history
…talog (#5710)

### What changes were proposed in this pull request?

add test 'list-all-tables'  for the Hive catalog

### Why are the changes needed?

Fix: #3783 

### Does this PR introduce _any_ user-facing change?

N/A

### How was this patch tested?

 CI passed
  • Loading branch information
chenyuan99 authored Dec 2, 2024
1 parent 8672ad7 commit 3b08dd7
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -620,6 +620,7 @@ public void testListTables() {
NameIdentifier icebergTable = NameIdentifier.of(schemaName, "iceberg_table");
NameIdentifier paimonTable = NameIdentifier.of(schemaName, "paimon_table");
NameIdentifier hudiTable = NameIdentifier.of(schemaName, "hudi_table");
NameIdentifier hiveTable = NameIdentifier.of(schemaName, "hive_table");
catalog
.asTableCatalog()
.createTable(icebergTable, createColumns(), null, ImmutableMap.of("table_type", "ICEBERG"));
Expand All @@ -629,8 +630,11 @@ public void testListTables() {
catalog
.asTableCatalog()
.createTable(hudiTable, createColumns(), null, ImmutableMap.of("provider", "hudi"));
catalog
.asTableCatalog()
.createTable(hiveTable, createColumns(), null, ImmutableMap.of("provider", "hive"));
NameIdentifier[] tables = catalog.asTableCatalog().listTables(Namespace.of(schemaName));
Assertions.assertEquals(0, tables.length);
Assertions.assertEquals(1, tables.length);
}

@Test
Expand Down

0 comments on commit 3b08dd7

Please sign in to comment.