diff --git a/src/app/dashboard/stats/page.test.tsx b/src/app/dashboard/stats/page.test.tsx new file mode 100644 index 00000000..4ff4015f --- /dev/null +++ b/src/app/dashboard/stats/page.test.tsx @@ -0,0 +1,14 @@ +import { describe, it, expect, vi } from 'vitest'; +import { render, screen } from '@testing-library/react'; +import DashboardStatsPage from './page'; + +vi.mock('@/components/DashboardStatsClient', () => ({ + default: () =>
Stats Client
+})); + +describe('DashboardStatsPage', () => { + it('renders the DashboardStatsClient component', () => { + render(); + expect(screen.getByTestId('mock-dashboard-stats-client')).toBeInTheDocument(); + }); +}); diff --git a/vitest.config.ts b/vitest.config.ts index 85834413..6584d3d8 100644 --- a/vitest.config.ts +++ b/vitest.config.ts @@ -23,6 +23,7 @@ export default defineConfig({ "src/components/SkillsCard.tsx", "src/components/LayoutEditor.tsx", "src/lib/rateLimit.ts", + "src/app/dashboard/stats/page.tsx", ], thresholds: { lines: 80,