mirror of
https://github.com/langflow-ai/langflow.git
synced 2026-07-25 16:09:31 +08:00
test: Fix race condition in rename flow test (#11549)
This commit is contained in:
committed by
GitHub
parent
732cf45979
commit
a24409e6bc
@ -39,6 +39,17 @@ export const renameFlow = async (
|
||||
await page.waitForSelector('[data-testid="sidebar-search-input"]', {
|
||||
timeout: 30000,
|
||||
});
|
||||
|
||||
if (flowName) {
|
||||
await page.waitForFunction(
|
||||
(expected) => {
|
||||
const header = document.querySelector('[data-testid="flow_name"]');
|
||||
return header && header.textContent?.trim() === expected;
|
||||
},
|
||||
flowName,
|
||||
{ timeout: 30000 },
|
||||
);
|
||||
}
|
||||
} else {
|
||||
await page.getByTestId("save-flow-settings").isDisabled({ timeout: 3000 });
|
||||
await page.getByTestId("cancel-flow-settings").isEnabled({ timeout: 3000 });
|
||||
|
||||
Reference in New Issue
Block a user