diff --git a/__tests__/AccountButtons.test.tsx.no b/__tests__/AccountButtons.test.tsx similarity index 57% rename from __tests__/AccountButtons.test.tsx.no rename to __tests__/AccountButtons.test.tsx index aa90351..39d41a2 100644 --- a/__tests__/AccountButtons.test.tsx.no +++ b/__tests__/AccountButtons.test.tsx @@ -3,9 +3,9 @@ import { render, screen } from '@testing-library/react'; import AccountButtons from '../src/components/account/AccountButtons.jsx'; describe('AccountButtons Component', () => { - it('should render the AccountButtons component', () => { + it('should render the Back link', () => { render(); - const accountButtonsElement = screen.getByRole('button', { name: /register/i }); - expect(accountButtonsElement).toBeInTheDocument(); + const backLinkElement = screen.getByRole('link', { name: /back/i }); + expect(backLinkElement).toBeInTheDocument(); }); }); diff --git a/__tests__/Card.test.tsx b/__tests__/Card.test.tsx index d8fb63b..49dd8c4 100644 --- a/__tests__/Card.test.tsx +++ b/__tests__/Card.test.tsx @@ -5,7 +5,7 @@ import Card from '../src/components/home/Card.jsx'; describe('Card Component', () => { it('should render the Card component with the given ID', () => { const testId = '123'; - render(); + render(); const cardElement = screen.getByText(/123/i); expect(cardElement).toBeInTheDocument(); @@ -13,7 +13,7 @@ describe('Card Component', () => { it('should store the ID in local storage when clicked', () => { const testId = '456'; - render(); + render(); const cardElement = screen.getByText(/456/i); fireEvent.click(cardElement); diff --git a/jest.config.ts b/jest.config.ts index f9b193f..2bb5326 100644 --- a/jest.config.ts +++ b/jest.config.ts @@ -6,6 +6,7 @@ const config: Config = { collectCoverage: true, collectCoverageFrom: [ "src/components/**/*.{js,jsx,ts,tsx}", // Include all components + "src/pages/**/*.{js,jsx,ts,tsx}", "!src/**/*.test.{js,jsx,ts,tsx}", // Exclude test files "!src/**/index.{js,jsx,ts,tsx}", // Optionally exclude index files ], diff --git a/src.zip b/src.zip deleted file mode 100644 index ca1d316..0000000 Binary files a/src.zip and /dev/null differ