From 4d3d864a7a81afb0e4c37292576455b56e879849 Mon Sep 17 00:00:00 2001 From: Siebe Vlietinck Date: Wed, 22 May 2024 11:27:50 +0200 Subject: [PATCH] other way of testing center button --- frontend/cypress/e2e/HomePageTests.cy.tsx | 5 ++--- frontend/tests/unit/header.test.tsx | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/frontend/cypress/e2e/HomePageTests.cy.tsx b/frontend/cypress/e2e/HomePageTests.cy.tsx index bec7f40e..8c8c5928 100644 --- a/frontend/cypress/e2e/HomePageTests.cy.tsx +++ b/frontend/cypress/e2e/HomePageTests.cy.tsx @@ -1,4 +1,4 @@ -describe("Homepage not logged in functionality", () => { +describe("Homepage functionality not logged in ", () => { it("Header Visible", () => { cy.visit("/"); cy.contains("PeristerĂ³nas"); @@ -9,9 +9,8 @@ describe("Homepage not logged in functionality", () => { cy.visit("/"); cy.contains("PeristerĂ³nas"); cy.get( - "a.MuiButtonBase-root.MuiButton-root.MuiButton-contained.MuiButton-containedPrimary.MuiButton-sizeMedium.MuiButton-containedSizeMedium.MuiButton-colorPrimary.MuiButton-root.MuiButton-contained.MuiButton-containedPrimary.MuiButton-sizeMedium.MuiButton-containedSizeMedium.MuiButton-colorPrimary.css-sghohy-MuiButtonBase-root-MuiButton-root" + "div.MuiContainer-root.MuiContainer-maxWidthSm.css-cuefkz-MuiContainer-root" ) - .eq(1) .contains("Login") .should("be.visible") .should("have.attr", "href") diff --git a/frontend/tests/unit/header.test.tsx b/frontend/tests/unit/header.test.tsx index 095636dc..76834646 100644 --- a/frontend/tests/unit/header.test.tsx +++ b/frontend/tests/unit/header.test.tsx @@ -1,5 +1,5 @@ import { describe, test } from "vitest"; -import { render } from "@testing-library/react"; +//import { render } from "@testing-library/react"; describe("Header", () => { test.todo("Header test");