2022-01-21 13:43:27 +01:00
|
|
|
import filterTests from "../support/filterTests"
|
2021-03-05 15:36:38 +01:00
|
|
|
|
2022-01-21 14:12:16 +01:00
|
|
|
filterTests(["smoke", "all"], () => {
|
2022-04-07 13:22:16 +02:00
|
|
|
/*
|
|
|
|
Blank screen
|
|
|
|
URL
|
|
|
|
Screen access
|
|
|
|
Screen access confirmation.
|
|
|
|
|
|
|
|
CRUD Tests
|
|
|
|
list the sources
|
|
|
|
check for exluded contents
|
|
|
|
rest, user table etc
|
|
|
|
*/
|
|
|
|
|
2022-02-17 15:06:17 +01:00
|
|
|
context("Screen Tests", () => {
|
2022-01-21 13:43:27 +01:00
|
|
|
before(() => {
|
|
|
|
cy.login()
|
|
|
|
cy.createTestApp()
|
|
|
|
cy.navigateToFrontend()
|
2021-07-28 09:09:37 +02:00
|
|
|
})
|
|
|
|
|
2022-01-21 13:43:27 +01:00
|
|
|
it("Should successfully create a screen", () => {
|
|
|
|
cy.createScreen("Test Screen", "/test")
|
|
|
|
cy.get(".nav-items-container").within(() => {
|
|
|
|
cy.contains("/test").should("exist")
|
|
|
|
})
|
2021-07-28 09:09:37 +02:00
|
|
|
})
|
2022-01-21 13:43:27 +01:00
|
|
|
|
|
|
|
it("Should update the url", () => {
|
|
|
|
cy.createScreen("Test Screen", "test with spaces")
|
|
|
|
cy.get(".nav-items-container").within(() => {
|
|
|
|
cy.contains("/test-with-spaces").should("exist")
|
|
|
|
})
|
|
|
|
})
|
2022-04-07 13:22:16 +02:00
|
|
|
|
|
|
|
it("Should update create the screen with the selected", () => {
|
|
|
|
cy.createScreen("Test Screen", "admin only", "Admin")
|
|
|
|
cy.get(".nav-items-container").within(() => {
|
|
|
|
cy.contains("/admin-only").should("exist")
|
|
|
|
})
|
|
|
|
})
|
2022-01-21 14:12:16 +01:00
|
|
|
})
|
2021-03-05 15:36:38 +01:00
|
|
|
})
|