refactor: time and use waitForSelector in filterSidebar.spec.ts (#4609)
* refactor: Improve time and use waitForSelector in filterSidebar.spec.ts * refactor: Improve time and use waitForSelector in filterSidebar.spec.ts
This commit is contained in:
parent
4965971901
commit
e6cd335b1c
1 changed files with 18 additions and 6 deletions
|
|
@ -24,18 +24,26 @@ test("user must see on handle click the possibility connections - LLMChain", asy
|
|||
|
||||
while (modalCount === 0) {
|
||||
await page.getByText("New Flow", { exact: true }).click();
|
||||
await page.waitForTimeout(3000);
|
||||
await page.waitForSelector('[data-testid="modal-title"]', {
|
||||
timeout: 3000,
|
||||
});
|
||||
modalCount = await page.getByTestId("modal-title")?.count();
|
||||
}
|
||||
await page.waitForTimeout(1000);
|
||||
await page.waitForSelector('[data-testid="blank-flow"]', {
|
||||
timeout: 3000,
|
||||
});
|
||||
|
||||
await page.getByTestId("blank-flow").click();
|
||||
await page.waitForTimeout(3000);
|
||||
await page.waitForSelector('[data-testid="sidebar-search-input"]', {
|
||||
timeout: 3000,
|
||||
});
|
||||
|
||||
await page.getByTestId("sidebar-search-input").click();
|
||||
await page.getByTestId("sidebar-search-input").fill("api request");
|
||||
|
||||
await page.waitForTimeout(1000);
|
||||
await page.waitForSelector('[data-testid="dataAPI Request"]', {
|
||||
timeout: 3000,
|
||||
});
|
||||
await page
|
||||
.getByTestId("dataAPI Request")
|
||||
.dragTo(page.locator('//*[@id="react-flow-id"]'));
|
||||
|
|
@ -45,8 +53,12 @@ test("user must see on handle click the possibility connections - LLMChain", asy
|
|||
await page.getByTestId("zoom_out").click();
|
||||
await page.getByTestId("zoom_out").click();
|
||||
await page.getByTestId("zoom_out").click();
|
||||
await page.waitForTimeout(500);
|
||||
|
||||
await page.waitForSelector(
|
||||
'[data-testid="handle-apirequest-shownode-urls-left"]',
|
||||
{
|
||||
timeout: 3000,
|
||||
},
|
||||
);
|
||||
await page.getByTestId("handle-apirequest-shownode-urls-left").click();
|
||||
|
||||
await page.waitForTimeout(500);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue