From d49ce24e097cdc68cf8a7a7fb77ffe9269c6b040 Mon Sep 17 00:00:00 2001 From: Jannat Patel Date: Fri, 17 Sep 2021 18:10:26 +0530 Subject: [PATCH] fix: web page and load time --- cypress/integration/discussions.js | 4 ++-- frappe/tests/ui_test_helpers.py | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cypress/integration/discussions.js b/cypress/integration/discussions.js index 198fe0b201..46b3f52cb9 100644 --- a/cypress/integration/discussions.js +++ b/cypress/integration/discussions.js @@ -8,7 +8,7 @@ context('Discussions', () => { }); const reply_through_modal = () => { - cy.visit('/test-page'); + cy.visit('/test-page-discussions'); // Open the modal cy.get('.reply').click(); @@ -26,7 +26,7 @@ context('Discussions', () => { // Submit cy.get('.modal .submit-discussion').click(); - cy.wait(3000); + cy.wait(20000); // Check if discussion is added to page and content is visible cy.get('.sidebar-parent:first .discussion-topic-title').should('have.text', 'Discussion from tests'); diff --git a/frappe/tests/ui_test_helpers.py b/frappe/tests/ui_test_helpers.py index fcb7cb0b61..c5d3851068 100644 --- a/frappe/tests/ui_test_helpers.py +++ b/frappe/tests/ui_test_helpers.py @@ -194,12 +194,12 @@ def create_form_tour(): @frappe.whitelist() def create_data_for_discussions(): - web_page = frappe.db.exists("Web Page", {"route": "test-page"}) + web_page = frappe.db.exists("Web Page", {"route": "test-page-discussions"}) if not web_page: web_page = frappe.get_doc({ "doctype": "Web Page", - "title": "Test Page", - "route": "test-page", + "title": "Test page for discussions", + "route": "test-page-discussions", "published": True }) web_page.save()