From eafeea416b503d62090382f1703098907f641d66 Mon Sep 17 00:00:00 2001 From: Raju Udava <86527202+dstala@users.noreply.github.com> Date: Tue, 27 Sep 2022 12:36:17 +0530 Subject: [PATCH] test: kludge, add wait for expand record Signed-off-by: Raju Udava <86527202+dstala@users.noreply.github.com> --- .../integration/common/1b_table_column_operations.js | 3 +++ .../integration/common/3f_link_to_another_record.js | 11 ++++++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/scripts/cypress/integration/common/1b_table_column_operations.js b/scripts/cypress/integration/common/1b_table_column_operations.js index 0a5369d498..f1d53f0895 100644 --- a/scripts/cypress/integration/common/1b_table_column_operations.js +++ b/scripts/cypress/integration/common/1b_table_column_operations.js @@ -10,6 +10,9 @@ export const genTest = (apiType, dbType) => { function addNewRow(index, cellValue) { cy.get(".nc-add-new-row-btn:visible").should("exist"); cy.get(".nc-add-new-row-btn").click(); + + cy.wait(2000); + // cy.get("#data-table-form-Title > input").first().type(cellValue); cy.get(".nc-expand-col-Title") .find(".nc-cell > input") diff --git a/scripts/cypress/integration/common/3f_link_to_another_record.js b/scripts/cypress/integration/common/3f_link_to_another_record.js index d409b1aacd..bf0a37b98b 100644 --- a/scripts/cypress/integration/common/3f_link_to_another_record.js +++ b/scripts/cypress/integration/common/3f_link_to_another_record.js @@ -285,13 +285,18 @@ export const genTest = (apiType, dbType) => { cy.intercept("GET", `/api/v1/db/data/noco/**`).as("waitForCardLoad"); addRow(3, "2c"); + + cy.wait(waitTime); + cy.get(".nc-row-expand").eq(2).click({ force: true }); + cy.wait(waitTime); + // wait for page render to complete cy.get('button:contains("Save row"):visible').should("exist"); // BT - cy.wait(1000); + cy.wait(waitTime); cy.get(".nc-expand-col-Sheet1") .find(".nc-action-icon") .should("exist") @@ -313,7 +318,7 @@ export const genTest = (apiType, dbType) => { .should("exist") .eq(2) .click(); - cy.wait(1000); + cy.wait(waitTime); // HM cy.get(".nc-expand-col-Link2-1hm").find(".ant-btn-primary").click(); @@ -324,7 +329,7 @@ export const genTest = (apiType, dbType) => { .should("exist") .eq(2) .click(); - cy.wait(1000); + cy.wait(waitTime); cy.getActiveDrawer(".nc-drawer-expanded-form") .find("button")