mirror of
https://github.com/nocodb/nocodb.git
synced 2026-05-02 13:16:48 +00:00
test: cy wait cleanup
Signed-off-by: Raju Udava <86527202+dstala@users.noreply.github.com>
This commit is contained in:
@@ -126,10 +126,9 @@ export class _mainPage {
|
||||
cy.getActiveModal(".nc-modal-invite-user-and-share-base")
|
||||
.find('input[placeholder="E-mail"]')
|
||||
.should("exist");
|
||||
cy.wait(1000);
|
||||
|
||||
cy.get('input[placeholder="E-mail"]').type(userCred.username);
|
||||
// cy.wait(1000);
|
||||
|
||||
cy.get('input[placeholder="E-mail"]:visible').type(userCred.username);
|
||||
cy.get(".ant-select.nc-user-roles").click();
|
||||
|
||||
// opt-in requested role & submit
|
||||
@@ -518,9 +517,8 @@ export class _mainPage {
|
||||
.find(".nc-project-menu-item")
|
||||
.contains("Download")
|
||||
.click();
|
||||
cy.wait(1000);
|
||||
cy.get(".nc-project-menu-item")
|
||||
.contains("Download as CSV")
|
||||
// cy.wait(1000);
|
||||
cy.get(".nc-project-menu-item:contains('Download as CSV')")
|
||||
.should("exist")
|
||||
.click();
|
||||
}
|
||||
@@ -593,9 +591,14 @@ export class _mainPage {
|
||||
}
|
||||
|
||||
metaSyncValidate(tbl, msg) {
|
||||
// http://localhost:8080/api/v1/db/meta/projects/p_bxp57hmks0n5o2/meta-diff
|
||||
cy.intercept("GET", "/api/v1/db/meta/projects/*").as("metaSync");
|
||||
|
||||
cy.get(".nc-btn-metasync-reload").should("exist").click();
|
||||
cy.wait(2000);
|
||||
cy.get(`.nc-metasync-row-${tbl}`).contains(msg).should("exist");
|
||||
// cy.wait(2000);
|
||||
cy.wait("@metaSync");
|
||||
|
||||
cy.get(`.nc-metasync-row-${tbl}:contains(${msg})`).should("exist");
|
||||
cy.get(".nc-btn-metasync-sync-now")
|
||||
.should("exist")
|
||||
.click()
|
||||
|
||||
@@ -114,7 +114,8 @@ export class _projectsPage {
|
||||
|
||||
// close team & auth tab
|
||||
cy.get("button.ant-tabs-tab-remove").should("exist").click();
|
||||
cy.wait(1000);
|
||||
cy.get("button.ant-tabs-tab-remove").should("not.exist");
|
||||
// cy.wait(1000);
|
||||
}
|
||||
|
||||
// Open existing project
|
||||
@@ -155,6 +156,8 @@ export class _projectsPage {
|
||||
cy.get(".nc-metadb-project-name").should("exist");
|
||||
cy.contains("button", "Create").should("exist");
|
||||
|
||||
// fix me! wait till the modal rendering (input highlight) is completed
|
||||
// focus shifts back to the input field to select text after the dropdown is rendered
|
||||
cy.wait(1000);
|
||||
|
||||
// feed project name
|
||||
@@ -185,7 +188,8 @@ export class _projectsPage {
|
||||
cy.get(".nc-extdb-proj-name").should("exist");
|
||||
cy.get(".nc-extdb-btn-test-connection").should("exist");
|
||||
|
||||
// CY goes too fast at times, so wait for the page to load
|
||||
// fix me! wait till the modal rendering (input highlight) is completed
|
||||
// focus shifts back to the input field to select text after the dropdown is rendered
|
||||
cy.wait(1000);
|
||||
|
||||
cy.get(".nc-extdb-proj-name").clear().type(projectName);
|
||||
@@ -208,7 +212,7 @@ export class _projectsPage {
|
||||
// Create project
|
||||
cy.contains("Ok & Save Project", { timeout: 20000 }).click();
|
||||
|
||||
cy.wait(5000);
|
||||
// cy.wait(5000);
|
||||
// takes a while to load project
|
||||
this.waitHomePageLoad();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user