From 41bd74a372ee606f009aa84ad4a8e4cbda66171e Mon Sep 17 00:00:00 2001 From: Qian Xia Date: Thu, 28 Mar 2024 13:58:10 +0800 Subject: [PATCH] [#2292] add web ui support for fileset catalog --- .../test/web/ui/CatalogsPageTest.java | 3 +-- .../test/web/ui/pages/CatalogsPage.java | 22 +++++-------------- .../app/metalakes/metalake/MetalakeView.js | 1 + 3 files changed, 7 insertions(+), 19 deletions(-) diff --git a/integration-test/src/test/java/com/datastrato/gravitino/integration/test/web/ui/CatalogsPageTest.java b/integration-test/src/test/java/com/datastrato/gravitino/integration/test/web/ui/CatalogsPageTest.java index cb1a1e88210..dcc2a1d0034 100644 --- a/integration-test/src/test/java/com/datastrato/gravitino/integration/test/web/ui/CatalogsPageTest.java +++ b/integration-test/src/test/java/com/datastrato/gravitino/integration/test/web/ui/CatalogsPageTest.java @@ -146,8 +146,7 @@ public void testClickSchemaLink() { @Test @Order(8) public void testClickTableLink() { - catalogsPage.clickTableLink( - metalakeName, modifiedCatalogName, catalogType, schemaName, tableName); + catalogsPage.clickTableLink(metalakeName, modifiedCatalogName, catalogType, schemaName, tableName); Assertions.assertTrue(catalogsPage.verifyShowTableTitle("Columns")); Assertions.assertTrue(catalogsPage.verifyTableColumns()); } diff --git a/integration-test/src/test/java/com/datastrato/gravitino/integration/test/web/ui/pages/CatalogsPage.java b/integration-test/src/test/java/com/datastrato/gravitino/integration/test/web/ui/pages/CatalogsPage.java index 1921f561a05..7230a4e00d9 100644 --- a/integration-test/src/test/java/com/datastrato/gravitino/integration/test/web/ui/pages/CatalogsPage.java +++ b/integration-test/src/test/java/com/datastrato/gravitino/integration/test/web/ui/pages/CatalogsPage.java @@ -190,14 +190,7 @@ public void clickDeleteCatalogBtn(String name) { public void clickCatalogLink(String metalakeName, String catalogName, String catalogType) { try { - String xpath = - "//a[@href='?metalake=" - + metalakeName - + "&catalog=" - + catalogName - + "&type=" - + catalogType - + "']"; + String xpath = "//a[@href='?metalake=" + metalakeName + "&catalog=" + catalogName + "&type=" + catalogType + "']"; WebElement link = tableGrid.findElement(By.xpath(xpath)); WebDriverWait wait = new WebDriverWait(driver, MAX_TIMEOUT); wait.until(ExpectedConditions.elementToBeClickable(By.xpath(xpath))); @@ -207,15 +200,14 @@ public void clickCatalogLink(String metalakeName, String catalogName, String cat } } - public void clickSchemaLink( - String metalakeName, String catalogName, String catalogType, String schemaName) { + public void clickSchemaLink(String metalakeName, String catalogName, String catalogType, String schemaName) { try { String xpath = "//a[@href='?metalake=" + metalakeName + "&catalog=" + catalogName - + "&type=" + +"&type=" + catalogType + "&schema=" + schemaName @@ -230,18 +222,14 @@ public void clickSchemaLink( } public void clickTableLink( - String metalakeName, - String catalogName, - String catalogType, - String schemaName, - String tableName) { + String metalakeName, String catalogName, String catalogType, String schemaName, String tableName) { try { String xpath = "//a[@href='?metalake=" + metalakeName + "&catalog=" + catalogName - + "&type=" + +"&type=" + catalogType + "&schema=" + schemaName diff --git a/web/src/app/metalakes/metalake/MetalakeView.js b/web/src/app/metalakes/metalake/MetalakeView.js index e700ff145fc..0c0a679a86e 100644 --- a/web/src/app/metalakes/metalake/MetalakeView.js +++ b/web/src/app/metalakes/metalake/MetalakeView.js @@ -26,6 +26,7 @@ import { getFilesetDetails, setSelectedNodes } from '@/lib/store/metalakes' +import { type } from 'os' const MetalakeView = () => { const dispatch = useAppDispatch()