From b624a6228d16958923548d8cb82b9863be9c7c64 Mon Sep 17 00:00:00 2001 From: SbloodyS <460888207@qq.com> Date: Mon, 1 Jul 2024 14:35:32 +0800 Subject: [PATCH] fix flaky e2e test --- .../dolphinscheduler/e2e/pages/datasource/DataSourcePage.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dolphinscheduler-e2e/dolphinscheduler-e2e-case/src/test/java/org/apache/dolphinscheduler/e2e/pages/datasource/DataSourcePage.java b/dolphinscheduler-e2e/dolphinscheduler-e2e-case/src/test/java/org/apache/dolphinscheduler/e2e/pages/datasource/DataSourcePage.java index ad1239f224da..16613e25b367 100644 --- a/dolphinscheduler-e2e/dolphinscheduler-e2e-case/src/test/java/org/apache/dolphinscheduler/e2e/pages/datasource/DataSourcePage.java +++ b/dolphinscheduler-e2e/dolphinscheduler-e2e-case/src/test/java/org/apache/dolphinscheduler/e2e/pages/datasource/DataSourcePage.java @@ -35,7 +35,6 @@ import org.openqa.selenium.support.FindBy; import org.openqa.selenium.support.FindBys; import org.openqa.selenium.support.PageFactory; -import org.openqa.selenium.support.ui.ExpectedCondition; import org.openqa.selenium.support.ui.ExpectedConditions; @Getter @@ -71,7 +70,8 @@ public DataSourcePage createDataSource(String dataSourceType, String dataSourceN WebDriverWaitFactory.createWebDriverWait(driver).until(ExpectedConditions.visibilityOf(dataSourceModal)); WebElement dataSourceTypeButton = By.className(dataSourceType.toUpperCase() + "-box").findElement(driver); - WebDriverWaitFactory.createWebDriverWait(driver).until(ExpectedConditions.elementToBeClickable(dataSourceTypeButton)); + WebDriverWaitFactory.createWebDriverWait(driver) + .until(ExpectedConditions.elementToBeClickable(dataSourceTypeButton)); dataSourceTypeButton.click(); WebDriverWaitFactory.createWebDriverWait(driver).until(ExpectedConditions.textToBePresentInElement(