#35514: Dictionary based EMAIL_PROVIDERS settings
-----------------------------+----------------------------------------
Reporter: Jacob Rief | Owner: Mike Edmunds
Type: New feature | Status: assigned
Component: Core (Mail) | Version: dev
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 1
Easy pickings: 0 | UI/UX: 0
-----------------------------+----------------------------------------
Comment (by nessita <124304+nessita@…>):
In [changeset:"3e0190a4586e71c92ead3c01323bf0cb9fe1a03c" 3e0190a4]:
{{{#!CommitTicketReference repository=""
revision="3e0190a4586e71c92ead3c01323bf0cb9fe1a03c"
Refs #35514 -- Decoupled settings from functional EmailBackend tests.
Reworked tests/mail/test_backends.py so that cases covering functional
behavior don't depend on EMAIL_BACKEND or other EMAIL_* settings. (But
kept unchanged existing tests to verify backend instance properties are
initialized from EMAIL_* settings.)
Most backend behavior tests had implicitly relied on email settings
overrides in test setup (e.g., to use an emulated SMTP server). They
either used mail.get_connection(...) or directly constructed a backend
class instance with the specific attributes being tested, relying on
the settings overrides to initialize other required attributes. That
approach won't work after those settings are deprecated as part of
EMAIL_PROVIDERS.
Instead, replaced backend construction in "functional" tests with new
SharedEmailBackendTests.create_backend() which constructs the testable
backend instance with _all_ options needed to avoid global settings.
Tests to verify the settings are read correctly continue to directly
construct backend instances, without using create_backend().
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/35514#comment:47>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion visit
https://groups.google.com/d/msgid/django-updates/0107019e0764e2b2-f6e90c8d-7012-4c86-a5cc-9494948d52fd-000000%40eu-central-1.amazonses.com.