summaryrefslogtreecommitdiffstats
path: root/cypress-docker/test/src/cypress/integration/mocks/newApp/errorDialog-spec.js
diff options
context:
space:
mode:
Diffstat (limited to 'cypress-docker/test/src/cypress/integration/mocks/newApp/errorDialog-spec.js')
-rw-r--r--cypress-docker/test/src/cypress/integration/mocks/newApp/errorDialog-spec.js26
1 files changed, 26 insertions, 0 deletions
diff --git a/cypress-docker/test/src/cypress/integration/mocks/newApp/errorDialog-spec.js b/cypress-docker/test/src/cypress/integration/mocks/newApp/errorDialog-spec.js
new file mode 100644
index 0000000..a9c889e
--- /dev/null
+++ b/cypress-docker/test/src/cypress/integration/mocks/newApp/errorDialog-spec.js
@@ -0,0 +1,26 @@
+describe("Dialog error - E2E test flow with mock", () => {
+ describe("Simulate errors", () => {
+ beforeEach(() => {
+ cy.getMCListEmpty();
+ cy.getTemplateApiError();
+ });
+
+ it("Simulate error dialog is visible", () => {
+ cy.get(".ui-dialog").should("be.visible");
+ });
+ it("Simulate error dialog is close by cancel button ", () => {
+ cy
+ .get('button[data-tests-id="error-cancel"]')
+ .first()
+ .click({ force: true });
+ cy.get(".ui-dialog").should("not.be.visible");
+ });
+ it("Simulate error dialog is close by X button ", () => {
+ cy
+ .get('span[data-tests-id="error-cancel-icon"]')
+ .first()
+ .click({ force: true });
+ cy.get(".ui-dialog").should("not.be.visible");
+ });
+ });
+});