fix: missing integration page routes

This commit is contained in:
fsylvain committed 2026-10-07 16:50:44 +02:00
1 parent 59c72a84ce
commit 28d2d5c826
7 files changed
+205 -24

No files matched your search

@@ -170,14 +170,14 @@ describe('Default, every card collapsed', () => {
expect(row(wrapper, 'POST /v1/article/').text()).toContain('POST')
})
it('groups the 20 cards as 7, 6, 6 and 1', async () => {
it('groups the 24 cards as 7, 10, 6 and 1', async () => {
const wrapper = await mountIntegration()
expect(
['articles', 'media', 'users', 'settings'].map(
(id) => section(wrapper, id).findAllComponents(EndpointCard).length,
),
).toEqual([7, 6, 6, 1])
).toEqual([7, 10, 6, 1])
expect(section(wrapper, 'articles').text()).toContain('7 routes')
expect(section(wrapper, 'settings').text()).toContain('1 route')
})
@@ -361,16 +361,16 @@ describe('Authentication', () => {
})
describe('Session only', () => {
it('renders the banner, 13 rows without expand controls and the 403 chips', async () => {
it('renders the banner, 17 rows without expand controls and the 403 chips', async () => {
const wrapper = await mountIntegration()
const session = section(wrapper, 'session')
expect(session.text()).toContain('13 routes')
expect(session.text()).toContain('17 routes')
expect(session.text()).toContain(
'These routes are made for a signed-in browser session. With an API key, verify, DELETE /auth/register, /api-key/* and /system/* answer 403 "This action needs a real session."',
'These routes are made for a signed-in browser session. With an API key, verify, DELETE /auth/register, PATCH /settings, /activity/*, /api-key/* and /system/* answer 403 "This action needs a real session."',
)
const rows = session.findAll('[data-session-row]')
expect(rows).toHaveLength(13)
expect(rows).toHaveLength(17)
expect(session.findAll('[data-session-row] button')).toHaveLength(0)
expect(session.findAll('[data-session-row] [aria-expanded]')).toHaveLength(0)
@@ -382,6 +382,10 @@ describe('Session only', () => {
'POST /v1/system/update/restart',
'POST /v1/auth/verify',
'DELETE /v1/auth/register',
'PATCH /v1/settings',
'GET /v1/activity',
'GET /v1/activity/summary',
'GET /v1/activity/export',
'GET /v1/api-key',
'POST /v1/api-key',
'DELETE /v1/api-key/{id}',