-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
Description
Notify the user via email when their scan job is complete. The implementation must handle different environments, sending real emails in production but printing to the console during development and testing to avoid spam and reliance on a real SMTP server.
Tasks:
- Configure Django's email settings. Use environment variables to switch between django.core.mail.backends.smtp.EmailBackend for production and django.core.mail.backends.console.EmailBackend for development (DEBUG=True).
- At the end of the perform_scan_task Celery task, add logic to call Django's send_mail function.
- The email should inform the user that their scan for a specific company is complete and include a link to the results page.
- Implement the reset password logic (from login)
- Write unit tests (scans/tests/test_notifications.py). Use mock to assert that send_mail is called with the correct subject, message, and recipient email address, without actually sending an email.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels