diff --git a/cypress.config.ts b/cypress.config.ts index 0c939ce50b3..3dff1aa6814 100644 --- a/cypress.config.ts +++ b/cypress.config.ts @@ -30,7 +30,6 @@ export default defineConfig({ baseUrl: "http://localhost:4000", retries: 2, requestTimeout: 15000, - excludeSpecPattern: "**/*roles.cy.ts", }, env: { API_URL: process.env.REACT_CARE_API_URL ?? "http://localhost:9000", diff --git a/cypress/e2e/auth_spec/roles.cy.ts b/cypress/e2e/auth_spec/roles.cy.ts deleted file mode 100644 index c84679de943..00000000000 --- a/cypress/e2e/auth_spec/roles.cy.ts +++ /dev/null @@ -1,19 +0,0 @@ -import * as users from "../../fixtures/users.json"; - -describe("authentication", () => { - users.forEach((user) => { - it("Login as " + user.username + " - " + user.rolename, () => { - cy.loginByApi(user.username, "passwordR0FL"); - cy.awaitUrl("/user/profile"); - cy.get("dd").should("contain", user.username); - cy.get("dd").should("contain", user.rolename); - }); - }); - afterEach(() => { - cy.log("Logging out"); - cy.get("#sign-out-button").contains("Sign Out").click(); - cy.getLocalStorage("care_access_token").should("be.null"); - cy.getLocalStorage("care_refresh_token").should("be.null"); - cy.url().should("include", "/"); - }); -}); diff --git a/cypress/fixtures/users.json b/cypress/fixtures/users.json deleted file mode 100644 index 3a935589846..00000000000 --- a/cypress/fixtures/users.json +++ /dev/null @@ -1,38 +0,0 @@ -[ - { - "username": "karadmin", - "rolename": "DistrictAdmin" - }, - { - "username": "karadminro", - "rolename": "DistrictReadOnlyAdmin" - }, - { - "username": "karstaff1", - "rolename": "Staff" - }, - { - "username": "karstaffro", - "rolename": "StaffReadOnly" - }, - { - "username": "karlocal", - "rolename": "LocalBodyAdmin" - }, - { - "username": "karward", - "rolename": "WardAdmin" - }, - { - "username": "kardoc1", - "rolename": "Doctor" - }, - { - "username": "karpharma1", - "rolename": "Pharmacist" - }, - { - "username": "karvol", - "rolename": "Volunteer" - } -]