Skip to content

Commit

Permalink
Merge branch 'develop' into r/workspace/authenticator
Browse files Browse the repository at this point in the history
  • Loading branch information
ReddixT authored Dec 30, 2022
2 parents aa76c0c + b4023b2 commit 9e56a1a
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 42 deletions.
10 changes: 3 additions & 7 deletions lumium-space/cypress/e2e/redirection.cy.ts
Original file line number Diff line number Diff line change
@@ -1,20 +1,16 @@
import { AUTH_SIGNIN, ACCOUNT, SPACES_NEW, SPACES_CREATE, SPACES_JOIN } from "@routes/space";
import { AUTH_SIGNIN, ACCOUNT, SPACES_OVERVIEW, SPACES_CREATE } from "@routes/space";

describe("redirection", () => {
it("redirect /account", () => {
cy.visit(ACCOUNT);
cy.url().should('include', AUTH_SIGNIN);
});
it("redirect /spaces/new", () => {
cy.visit(SPACES_NEW);
it("redirect /spaces/overview", () => {
cy.visit(SPACES_OVERVIEW);
cy.url().should('include', AUTH_SIGNIN);
});
it("redirect /spaces/create", () => {
cy.visit(SPACES_CREATE);
cy.url().should('include', AUTH_SIGNIN);
});
it("redirect /spaces/join", () => {
cy.visit(SPACES_JOIN);
cy.url().should('include', AUTH_SIGNIN);
});
});
1 change: 0 additions & 1 deletion lumium-space/cypress/e2e/spaces_create.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ describe("/spaces/new", () => {
cy.dataCy("passwordConfirmInput").should("be.visible").type(password);
cy.dataCy("nextButton").should("be.visible").click();
cy.dataCy("downloadButton").should("be.visible").click();
cy.dataCy("submitButton").should("be.visible").click();
cy.deleteAccount();
});
});
Expand Down
11 changes: 0 additions & 11 deletions lumium-space/cypress/e2e/spaces_join.cy.ts

This file was deleted.

20 changes: 0 additions & 20 deletions lumium-space/cypress/e2e/spaces_new.cy.ts

This file was deleted.

12 changes: 12 additions & 0 deletions lumium-space/cypress/e2e/spaces_overview.cy.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { SPACES_CREATE, SPACES_OVERVIEW } from "@routes/space";

describe("/spaces/overview", () => {
it("create button redirection", () => {
cy.signUp().then(() => {
cy.visit(SPACES_OVERVIEW);
cy.dataCy("createButton").should("be.visible").click();
cy.url().should('include', SPACES_CREATE);
cy.deleteAccount();
});
});
});
6 changes: 3 additions & 3 deletions lumium-space/cypress/support/commands.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ACCOUNT, AUTH_PASSWORD_RESET, AUTH_SIGNIN, AUTH_SIGNUP, SPACES_NEW } from "@routes/space";
import { ACCOUNT, AUTH_PASSWORD_RESET, AUTH_SIGNIN, AUTH_SIGNUP, SPACES_OVERVIEW } from "@routes/space";
import { makeid } from "./makeid"

declare global {
Expand Down Expand Up @@ -37,7 +37,7 @@ Cypress.Commands.add("signUp", () => {
cy.dataCy("signUpButton").should("be.visible").click().then(() => {
cy.wait(3000);
cy.getCookie('accessToken').should("not.be.null");
cy.url().should('include', SPACES_NEW);
cy.url().should('include', SPACES_OVERVIEW);
});
return cy.wrap([email, password]);
});
Expand All @@ -51,7 +51,7 @@ Cypress.Commands.add("signIn", (email: string, password: string) => {
cy.wait(3000);
cy.getCookie('accessToken').should("not.be.null");
});
cy.url().should('include', SPACES_NEW);
cy.url().should('include', SPACES_OVERVIEW);
});

Cypress.Commands.add("signOut", () => {
Expand Down

0 comments on commit 9e56a1a

Please sign in to comment.