|
|
@ -49,7 +49,6 @@ Cypress.Commands.add("deleteApp", () => { |
|
|
cy.request(`localhost:${Cypress.env("PORT")}/api/applications?status=all`) |
|
|
cy.request(`localhost:${Cypress.env("PORT")}/api/applications?status=all`) |
|
|
.its("body") |
|
|
.its("body") |
|
|
.then(val => { |
|
|
.then(val => { |
|
|
console.log(val) |
|
|
|
|
|
if (val.length > 0) { |
|
|
if (val.length > 0) { |
|
|
cy.get(".title > :nth-child(3) > .spectrum-Icon").click() |
|
|
cy.get(".title > :nth-child(3) > .spectrum-Icon").click() |
|
|
cy.contains("Delete").click() |
|
|
cy.contains("Delete").click() |
|
|
@ -186,8 +185,16 @@ Cypress.Commands.add("navigateToFrontend", () => { |
|
|
Cypress.Commands.add("createScreen", (screenName, route) => { |
|
|
Cypress.Commands.add("createScreen", (screenName, route) => { |
|
|
cy.get("[aria-label=AddCircle]").click() |
|
|
cy.get("[aria-label=AddCircle]").click() |
|
|
cy.get(".spectrum-Modal").within(() => { |
|
|
cy.get(".spectrum-Modal").within(() => { |
|
|
cy.get("input").first().type(screenName) |
|
|
cy.get(".item").first().click() |
|
|
cy.get("input").eq(1).type(route) |
|
|
cy.get(".spectrum-Button--cta").click() |
|
|
|
|
|
}) |
|
|
|
|
|
cy.get(".spectrum-Modal").within(() => { |
|
|
|
|
|
cy.get("input").first().clear().type(screenName) |
|
|
|
|
|
cy.get("input").eq(1).clear().type(route) |
|
|
|
|
|
cy.get(".spectrum-Button--cta").click() |
|
|
|
|
|
}) |
|
|
|
|
|
cy.get(".spectrum-Modal").within(() => { |
|
|
|
|
|
cy.get(`[data-cy="left-nav"]`).click() |
|
|
cy.get(".spectrum-Button--cta").click() |
|
|
cy.get(".spectrum-Button--cta").click() |
|
|
}) |
|
|
}) |
|
|
}) |
|
|
}) |
|
|
|