diff --git a/src/pages/admin/AdminApp.test.tsx b/src/pages/admin/AdminApp.test.tsx
index 06a0c55..1167b63 100644
--- a/src/pages/admin/AdminApp.test.tsx
+++ b/src/pages/admin/AdminApp.test.tsx
@@ -9,7 +9,15 @@ vi.mock('../../lib/supabase', () => ({
supabase: {
auth: { signOut: vi.fn() },
from: () => ({
- select: () => ({ order: () => Promise.resolve({ data: [], error: null }) }),
+ select: () => ({
+ order: () => Promise.resolve({ data: [], error: null }),
+ eq: () => ({
+ single: () => Promise.resolve({
+ data: { id: 'default', hero_headline: '', hero_tagline: '', about_bio: '', about_portrait_image: '', contact_email: '', contact_hours: '' },
+ error: null,
+ }),
+ }),
+ }),
}),
},
}))
@@ -61,4 +69,37 @@ describe('AdminApp routing', () => {
)
expect(await screen.findByRole('heading', { name: /^produits$/i })).toBeInTheDocument()
})
+
+ it('renders the AdminContent page at /admin/content', async () => {
+ render(
+
+
+ } />
+
+ ,
+ )
+ expect(await screen.findByRole('heading', { name: /^contenu$/i })).toBeInTheDocument()
+ })
+
+ it('renders the AdminTestimonials page at /admin/testimonials', async () => {
+ render(
+
+
+ } />
+
+ ,
+ )
+ expect(await screen.findByRole('heading', { name: /^témoignages$/i })).toBeInTheDocument()
+ })
+
+ it('renders the AdminRules page at /admin/rules', async () => {
+ render(
+
+
+ } />
+
+ ,
+ )
+ expect(await screen.findByRole('heading', { name: /^règlements$/i })).toBeInTheDocument()
+ })
})
diff --git a/src/pages/admin/AdminApp.tsx b/src/pages/admin/AdminApp.tsx
index 85d0882..9415586 100644
--- a/src/pages/admin/AdminApp.tsx
+++ b/src/pages/admin/AdminApp.tsx
@@ -7,6 +7,9 @@ import AdminServices from './AdminServices'
import AdminSchedule from './AdminSchedule'
import AdminBookings from './AdminBookings'
import AdminInquiries from './AdminInquiries'
+import AdminContent from './AdminContent'
+import AdminTestimonials from './AdminTestimonials'
+import AdminRules from './AdminRules'
import styles from './AdminApp.module.css'
function AdminApp() {
@@ -22,6 +25,9 @@ function AdminApp() {
} />
} />
} />
+ } />
+ } />
+ } />
} />
diff --git a/src/pages/admin/AdminLayout.tsx b/src/pages/admin/AdminLayout.tsx
index 8006c74..9c09137 100644
--- a/src/pages/admin/AdminLayout.tsx
+++ b/src/pages/admin/AdminLayout.tsx
@@ -8,6 +8,9 @@ const NAV_ITEMS = [
{ to: '/admin/schedule', label: 'Horaire' },
{ to: '/admin/bookings', label: 'Réservations' },
{ to: '/admin/inquiries', label: 'Demandes' },
+ { to: '/admin/content', label: 'Contenu' },
+ { to: '/admin/testimonials', label: 'Témoignages' },
+ { to: '/admin/rules', label: 'Règlements' },
]
function AdminLayout() {