feat(summary): send complete articles within user budget (#39)

This commit is contained in:
2026-11-24 17:39:26 +01:00
parent d0c7cb7cae
commit 79953ce49f
73 changed files with 1688 additions and 288 deletions

View File

@ -57,6 +57,7 @@ describe('Mes préférences', () => {
await waitFor(() => expect(updatePreferences).toHaveBeenCalledWith({
language: 'en',
ranking_mode: 'title_content',
summary_prompt_token_budget: 250000,
}))
})
it('charge les valeurs françaises et affiche les libellés et l’aide', async () => {
@ -81,7 +82,7 @@ describe('Mes préférences', () => {
await user.selectOptions(screen.getByLabelText(/informations utilisées par Laya/i), 'title')
await user.click(screen.getByRole('button', { name: 'Enregistrer' }))
expect(await screen.findByRole('status')).toHaveTextContent('Préférences enregistrées.')
expect(updatePreferences).toHaveBeenLastCalledWith({ language: 'fr', ranking_mode: 'title' })
expect(updatePreferences).toHaveBeenLastCalledWith({ language: 'fr', ranking_mode: 'title', summary_prompt_token_budget: 250000 })
view.unmount()
render(<Preferences />)
expect(await screen.findByLabelText(/langue/i)).toHaveValue('fr')