diff --git a/frontend/test/metabase/scenarios/dashboard/dashboard-management.cy.spec.js b/frontend/test/metabase/scenarios/dashboard/dashboard-management.cy.spec.js index e064d33f2246606cf41a4fbba8e36cfe21161880..d6f885ad7a3594819d2834255be46015e904defa 100644 --- a/frontend/test/metabase/scenarios/dashboard/dashboard-management.cy.spec.js +++ b/frontend/test/metabase/scenarios/dashboard/dashboard-management.cy.spec.js @@ -76,30 +76,30 @@ describe("managing dashboard from the dashboard's edit menu", () => { cy.findByText(`Orders in a dashboard - Duplicate`); }); - describe("move", () => { - beforeEach(() => { - popover().within(() => { - cy.findByText("Move").click(); - }); - cy.location("pathname").should("eq", "/dashboard/1/move"); - modal().within(() => { - cy.findByText("First collection").click(); - clickButton("Move"); - }); - }); + it("should be able to move/undo move a dashboard (metabase#13059)", () => { + cy.findByTestId("app-bar").contains("Our analytics"); - it("should be able to move/undo move a dashboard", () => { - assertOnRequest("updateDashboard"); - // Why do we use "Dashboard moved to" here (without its location, btw) vs. "Moved dashboard" for the same action? - cy.findByText("Dashboard moved to"); - cy.findByText("Undo").click(); - assertOnRequest("updateDashboard"); + popover().within(() => { + cy.findByText("Move").click(); }); + cy.location("pathname").should("eq", "/dashboard/1/move"); - it.skip("should update dashboard's collection after the move without page reload (metabase#13059)", () => { - cy.contains("37.65"); - cy.get(".DashboardHeader a").contains("First collection"); + modal().within(() => { + cy.findByText("First collection").click(); + clickButton("Move"); }); + + assertOnRequest("updateDashboard"); + cy.contains("37.65"); + // it should update dashboard's collection after the move without the page reload (metabase#13059) + cy.findByTestId("app-bar").contains("First collection"); + + // Why do we use "Dashboard moved to" here (without its location, btw) vs. "Moved dashboard" for the same action? + cy.findByText("Dashboard moved to"); + cy.findByText("Undo").click(); + assertOnRequest("updateDashboard"); + + cy.findByTestId("app-bar").contains("Our analytics"); }); it("should be able to archive/unarchive a dashboard", () => {