From c7dd9f354ad2f52f18389b691e3531bf49c8984e Mon Sep 17 00:00:00 2001 From: akash-codemonk <67054171+akash-codemonk@users.noreply.github.com> Date: Wed, 21 Jun 2023 16:43:51 +0530 Subject: [PATCH] chore: log editor state on test failure (#24703) Added some logs to be printed on failure. Hoping this would help in debugging the loading issue. Will remove it later once it is fixed. Related to https://github.com/appsmithorg/appsmith/issues/23713 --- app/client/cypress/support/e2e.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/app/client/cypress/support/e2e.js b/app/client/cypress/support/e2e.js index 665be083e3..828d532522 100644 --- a/app/client/cypress/support/e2e.js +++ b/app/client/cypress/support/e2e.js @@ -43,6 +43,13 @@ Cypress.on("uncaught:exception", () => { }); Cypress.on("fail", (error) => { + cy.window() + .its("store") + .invoke("getState") + .then((state) => { + cy.log(`Editor initialised: ${state.ui.editor.initialized}`); + cy.log(`Loading guided tour: ${state.ui.guidedTour.loading}`); + }); throw error; // throw error to have test still fail });