[E2E] Fix flaky udf manage e2e test (#8232)
* fix_file_manage_e2e_error * fix error * fix error * fix error
This commit is contained in:
parent
f3d663a7ea
commit
6094927dda
|
|
@ -37,8 +37,11 @@ import org.junit.jupiter.api.AfterAll;
|
|||
import org.junit.jupiter.api.BeforeAll;
|
||||
import org.junit.jupiter.api.Order;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.openqa.selenium.By;
|
||||
import org.openqa.selenium.WebElement;
|
||||
import org.openqa.selenium.remote.RemoteWebDriver;
|
||||
import org.openqa.selenium.support.ui.ExpectedConditions;
|
||||
import org.openqa.selenium.support.ui.WebDriverWait;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileOutputStream;
|
||||
|
|
@ -109,7 +112,8 @@ public class UdfManageE2ETest {
|
|||
void testCreateDirectory() {
|
||||
final UdfManagePage page = new UdfManagePage(browser);
|
||||
|
||||
browser.navigate().refresh();
|
||||
new WebDriverWait(page.driver(), 10)
|
||||
.until(ExpectedConditions.urlContains("/#/resource/udf"));
|
||||
|
||||
page.createDirectory(testDirectoryName, "test_desc");
|
||||
|
||||
|
|
@ -164,6 +168,8 @@ public class UdfManageE2ETest {
|
|||
|
||||
page.uploadFile(testUploadUdfFilePath.toFile().getAbsolutePath());
|
||||
|
||||
new WebDriverWait(browser, 10).until(ExpectedConditions.invisibilityOfElementLocated(By.id("fileUpdateDialog")));
|
||||
|
||||
await().untilAsserted(() -> {
|
||||
assertThat(page.udfList())
|
||||
.as("File list should contain newly-created file")
|
||||
|
|
|
|||
Loading…
Reference in New Issue