feat(#112): email accusé resoumission aux parents
Après PATCH reprise-resoumettre (parent), envoi à chaque parent du dossier : confirmation resoumission + rappel numero_dossier. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -98,4 +98,21 @@ describe('MailService (ticket #28)', () => {
|
||||
expect(html).toContain(`https://app.test/reset-password?token=${encodeURIComponent(token)}`);
|
||||
expect(html).not.toContain('create-password');
|
||||
});
|
||||
|
||||
it('sendResoumissionPendingEmail — accusé resoumission avec n° dossier', async () => {
|
||||
await service.sendResoumissionPendingEmail(
|
||||
'parent@test.fr',
|
||||
'Claire',
|
||||
'MARTIN',
|
||||
'2026-000024',
|
||||
);
|
||||
expect(sendEmailSpy).toHaveBeenCalledTimes(1);
|
||||
const [to, subject, html] = sendEmailSpy.mock.calls[0];
|
||||
expect(to).toBe('parent@test.fr');
|
||||
expect(subject).toContain('resoumis');
|
||||
expect(subject).toContain('2026-000024');
|
||||
expect(html).toContain('Claire');
|
||||
expect(html).toContain('2026-000024');
|
||||
expect(html).toContain('en attente de validation');
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user