From a9f50556d3956af97eff859fd4e1ba6ca72d8c58 Mon Sep 17 00:00:00 2001 From: Andrew Kingston Date: Wed, 7 Apr 2021 15:08:59 +0100 Subject: [PATCH] Fix cypress tests not deleting old apps --- packages/builder/cypress/support/commands.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/builder/cypress/support/commands.js b/packages/builder/cypress/support/commands.js index 4a8d0b39d3..7ac317142d 100644 --- a/packages/builder/cypress/support/commands.js +++ b/packages/builder/cypress/support/commands.js @@ -57,9 +57,9 @@ Cypress.Commands.add("createApp", name => { Cypress.Commands.add("deleteApp", name => { cy.visit(`localhost:${Cypress.env("PORT")}/builder`) - cy.get("body").then($body => { + cy.get(".apps").then($apps => { cy.wait(1000) - if ($body.find(`[data-cy="app-${name}"]`).length) { + if ($apps.find(`[data-cy="app-${name}"]`).length) { cy.get(`[data-cy="app-${name}"] a`).click() cy.get("[data-cy=settings-icon]").click() cy.get(".modal-content").within(() => {