diff --git a/app/client/cypress/fixtures/listwidgetdsl.json b/app/client/cypress/fixtures/listwidgetdsl.json index 00ce42b5cf..f34952103f 100644 --- a/app/client/cypress/fixtures/listwidgetdsl.json +++ b/app/client/cypress/fixtures/listwidgetdsl.json @@ -104,7 +104,7 @@ }, { "isVisible": true, - "text": "{{currentItem.num}}", + "text": "{{currentItem.email}}", "fontSize": "PARAGRAPH", "fontStyle": "BOLD", "textAlign": "LEFT", @@ -241,7 +241,7 @@ }, "Text2": { "isVisible": true, - "text": "{{List1.listData.map((currentItem) => currentItem.num)}}", + "text": "{{List1.listData.map((currentItem) => currentItem.email)}}", "fontSize": "PARAGRAPH", "fontStyle": "BOLD", "textAlign": "LEFT", diff --git a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Binding/Bind_API_with_List_Widget_spec.js b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Binding/Bind_API_with_List_Widget_spec.js index f27344fd8d..079fc24989 100644 --- a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Binding/Bind_API_with_List_Widget_spec.js +++ b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/Binding/Bind_API_with_List_Widget_spec.js @@ -32,7 +32,7 @@ describe("Test Create Api and Bind to Table widget", function() { it("Test_Validate the Api data is updated on List widget", function() { cy.SearchEntityandOpen("List1"); cy.testJsontext("items", "{{Api1.data.users}}"); - cy.get(".t--draggable-textwidget span").should("have.length.gte", 8); + cy.get(".t--draggable-textwidget span").should("have.length", 8); cy.get(".t--draggable-textwidget span") .first() .invoke("text") @@ -50,7 +50,7 @@ describe("Test Create Api and Bind to Table widget", function() { }, ).then(() => cy.wait(500)); - cy.get(".t--widget-textwidget span").should("have.length.gte", 8); + cy.get(".t--widget-textwidget span").should("have.length", 8); cy.get(".t--widget-textwidget span") .first() .invoke("text") @@ -63,7 +63,7 @@ describe("Test Create Api and Bind to Table widget", function() { cy.get(publishPage.backToEditor).click({ force: true }); cy.SearchEntityandOpen("List1"); cy.testJsontext("itemspacing\\(px\\)", "50"); - cy.get(".t--draggable-textwidget span").should("have.length.gte", 6); + cy.get(".t--draggable-textwidget span").should("have.length", 6); cy.get(".t--draggable-textwidget span") .first() .invoke("text") @@ -79,7 +79,7 @@ describe("Test Create Api and Bind to Table widget", function() { interval: 1000, }, ).then(() => cy.wait(500)); - cy.get(".t--widget-textwidget span").should("have.length.gte", 6); + cy.get(".t--widget-textwidget span").should("have.length", 6); cy.get(".t--widget-textwidget span") .first() .invoke("text") diff --git a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/DisplayWidgets/Switchgroup_spec.js b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/DisplayWidgets/Switchgroup_spec.js index 1783fb1604..dd8cfac37d 100644 --- a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/DisplayWidgets/Switchgroup_spec.js +++ b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/DisplayWidgets/Switchgroup_spec.js @@ -4,9 +4,10 @@ const explorer = require("../../../../locators/explorerlocators.json"); describe("Switchgroup Widget Functionality", function() { before(() => { cy.addDsl(dsl); + cy.wait(5000); }); - it("Add a new switch group widget with others", () => { + it("1. Add a new switch group widget with others", () => { cy.get(explorer.addWidget).click(); cy.dragAndDropToCanvas("switchgroupwidget", { x: 300, y: 300 }); cy.get(".t--widget-switchgroupwidget").should("exist"); @@ -20,7 +21,7 @@ describe("Switchgroup Widget Functionality", function() { ); }); - it("should check that empty value is allowed in options", () => { + it("2. Should check that empty value is allowed in options", () => { cy.openPropertyPane("switchgroupwidget"); cy.updateCodeInput( ".t--property-control-options", @@ -44,7 +45,7 @@ describe("Switchgroup Widget Functionality", function() { ); }); - it("should check that more thatn empty value is not allowed in options", () => { + it("3. Should check that more thatn empty value is not allowed in options", () => { cy.openPropertyPane("switchgroupwidget"); cy.updateCodeInput( ".t--property-control-options", @@ -68,7 +69,7 @@ describe("Switchgroup Widget Functionality", function() { ); }); - it("setting selectedValues to undefined does not crash the app", () => { + it("4. Setting selectedValues to undefined does not crash the app", () => { // Reset options for switch group cy.openPropertyPane("switchgroupwidget"); cy.updateCodeInput( @@ -99,11 +100,12 @@ describe("Switchgroup Widget Functionality", function() { .find(".t--js-toggle") .click(); // wait for a cyclic dependency error to occur - cy.wait(2000); + cy.validateToastMessage("Cyclic dependency found while evaluating"); // check if a crash messsge is appeared cy.get(".t--widget-switchgroupwidget") .contains("Oops, Something went wrong.") .should("not.exist"); + cy.wait(1000); // check if the evaluation is disabled cy.get(".t--widget-textwidget").should( "contain", diff --git a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/GitSync/Git_spec.js b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/GitSync/Git_spec.js index b0f88703fb..10e298e09e 100644 --- a/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/GitSync/Git_spec.js +++ b/app/client/cypress/integration/Smoke_TestSuite/ClientSideTests/GitSync/Git_spec.js @@ -201,29 +201,29 @@ describe("Git sync:", function() { cy.get(gitSyncLocators.closeGitSyncModal).click({ force: true }); }); - after(() => { - cy.deleteTestGithubRepo(repoName); + // after(() => { + // cy.deleteTestGithubRepo(repoName); - // TODO remove when app deletion with conflicts is fixed - cy.get(homePage.homeIcon).click({ force: true }); - cy.get(homePage.createNew) - .first() - .click({ force: true }); - cy.wait("@createNewApplication").should( - "have.nested.property", - "response.body.responseMeta.status", - 201, - ); - cy.get("#loading").should("not.exist"); - // eslint-disable-next-line cypress/no-unnecessary-waiting - cy.wait(2000); + // // TODO remove when app deletion with conflicts is fixed + // cy.get(homePage.homeIcon).click({ force: true }); + // cy.get(homePage.createNew) + // .first() + // .click({ force: true }); + // cy.wait("@createNewApplication").should( + // "have.nested.property", + // "response.body.responseMeta.status", + // 201, + // ); + // cy.get("#loading").should("not.exist"); + // // eslint-disable-next-line cypress/no-unnecessary-waiting + // cy.wait(2000); - cy.AppSetupForRename(); - cy.get(homePage.applicationName).type(repoName + "{enter}"); - cy.wait("@updateApplication").should( - "have.nested.property", - "response.body.responseMeta.status", - 200, - ); - }); + // cy.AppSetupForRename(); + // cy.get(homePage.applicationName).type(repoName + "{enter}"); + // cy.wait("@updateApplication").should( + // "have.nested.property", + // "response.body.responseMeta.status", + // 200, + // ); + // }); }); diff --git a/app/client/cypress/support/commands.js b/app/client/cypress/support/commands.js index 3d3d3c79b4..4ae88d7e22 100644 --- a/app/client/cypress/support/commands.js +++ b/app/client/cypress/support/commands.js @@ -3177,7 +3177,7 @@ Cypress.Commands.add("assertEvaluatedValuePopup", (expectedType) => { }); Cypress.Commands.add("validateToastMessage", (value) => { - cy.get(commonlocators.toastMsg).should("have.text", value); + cy.get(commonlocators.toastMsg).should("contain.text", value); }); Cypress.Commands.add("NavigateToPaginationTab", () => {