|
|
|
@ -1,4 +1,5 @@ |
|
|
|
import filterTests from "../support/filterTests" |
|
|
|
import { APP_TABLE_APP_NAME, DEPLOY_SUCCESS_MODAL } from "../support/interact"; |
|
|
|
const interact = require('../support/interact') |
|
|
|
|
|
|
|
filterTests(['all'], () => { |
|
|
|
@ -20,10 +21,10 @@ filterTests(['all'], () => { |
|
|
|
|
|
|
|
cy.get(interact.APP_TABLE_ROW_ACTION).eq(0) |
|
|
|
.within(() => { |
|
|
|
cy.get(interact.SPECTRUM_BUTTON_TEMPLATE).contains("Preview") |
|
|
|
//cy.get(interact.SPECTRUM_BUTTON_TEMPLATE).contains("Preview")
|
|
|
|
cy.get(interact.SPECTRUM_BUTTON_TEMPLATE).contains("Edit").click({ force: true }) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
cy.get(interact.DEPLOYMENT_TOP_NAV_GLOBESTRIKE).should("exist") |
|
|
|
cy.get(interact.DEPLOYMENT_TOP_GLOBE).should("not.exist") |
|
|
|
}) |
|
|
|
@ -39,7 +40,7 @@ filterTests(['all'], () => { |
|
|
|
}); |
|
|
|
|
|
|
|
//Verify that the app url is presented correctly to the user
|
|
|
|
cy.get(interact.DEPLOY_APP_MODAL) |
|
|
|
cy.get(interact.DEPLOY_SUCCESS_MODAL) |
|
|
|
.should("be.visible") |
|
|
|
.within(() => { |
|
|
|
let appUrl = Cypress.config().baseUrl + '/app/cypress-tests' |
|
|
|
@ -63,7 +64,7 @@ filterTests(['all'], () => { |
|
|
|
}) |
|
|
|
|
|
|
|
cy.get(interact.DEPLOYMENT_TOP_GLOBE).should("exist").click({ force: true }) |
|
|
|
|
|
|
|
|
|
|
|
cy.get(interact.PUBLISH_POPOVER_MENU).should("be.visible") |
|
|
|
.within(() => { |
|
|
|
cy.get(interact.PUBLISH_POPOVER_ACTION).should("exist") |
|
|
|
@ -72,9 +73,9 @@ filterTests(['all'], () => { |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
it("Should unpublish an application from the top navigation and reflect the status change", () => { |
|
|
|
it("Should unpublish an application using the link and reflect the status change", () => { |
|
|
|
//Assuming the previous test app exists and is published
|
|
|
|
|
|
|
|
|
|
|
|
cy.visit(`${Cypress.config().baseUrl}/builder`) |
|
|
|
|
|
|
|
cy.get(interact.APP_TABLE_STATUS).eq(0) |
|
|
|
@ -85,17 +86,11 @@ filterTests(['all'], () => { |
|
|
|
|
|
|
|
cy.get(interact.APP_TABLE_ROW_ACTION).eq(0) |
|
|
|
.within(() => { |
|
|
|
cy.get(interact.SPECTRUM_BUTTON).contains("View app") |
|
|
|
cy.get(interact.SPECTRUM_BUTTON).contains("Edit").click({ force: true }) |
|
|
|
cy.get(interact.SPECTRUM_BUTTON).contains("View") |
|
|
|
cy.get(interact.APP_TABLE_APP_NAME).click({ force: true }) |
|
|
|
}) |
|
|
|
|
|
|
|
//The published status
|
|
|
|
cy.get(interact.DEPLOYMENT_TOP_GLOBE).should("exist") |
|
|
|
.click({ force: true }) |
|
|
|
|
|
|
|
cy.get(interact.PUBLISH_POPOVER_MENU).should("be.visible") |
|
|
|
cy.get("[data-cy='publish-popover-menu'] [data-cy='publish-popover-action']") |
|
|
|
.click({ force : true }) |
|
|
|
cy.get(interact.SPECTRUM_LINK).contains('Unpublish').click(); |
|
|
|
|
|
|
|
cy.get(interact.UNPUBLISH_MODAL).should("be.visible") |
|
|
|
.within(() => { |
|
|
|
|