| Age | Commit message (Collapse) | Author |
|
See DEP 0018.
Added:
* MAILERS setting.
* django.core.mail.mailers dict-like EmailBackend factory.
* `using` argument to mail sending APIs.
* `sent_using` attribute to mail.outbox messages in locmem backend.
* MAILERS in startproject settings template, set to console backend.
* AdminLogHandler.using argument.
* BrokenLinkEmailsMiddleware.send_mail() method.
Updated:
* BaseEmailBackend to track the MAILERS alias used to construct it, and
to report errors for unknown kwargs (OPTIONS).
* EmailBackend implementations to initialize from kwargs (OPTIONS) only
when MAILERS is being used.
* smtp.EmailBackend to require `host` option and to default `port`
option based on SSL/TLS options.
* SimpleTestCase setup to substitute the locmem backend for all defined
MAILERS configurations.
* Django's tests that send mail to define MAILERS.
Deprecated:
* EMAIL_BACKEND and other backend-related EMAIL_* settings.
* mail.get_connection().
* The `connection`, `fail_silently`, `auth_user`, and `auth_password`
arguments to mail functions.
* The EmailMessage.connection attribute.
* BaseEmailBackend support for `fail_silently`. Backends that support
fail_silently (SMTP, console, file) now implement it directly.
* AdminEmailHandler.email_backend argument.
Removed undocumented features without deprecation:
* EmailMessage.get_connection() method. (send() now raises an error if a
subclass has attempted to override it.)
* EmailMessage.send() no longer sets self.connection to the connection
used for sending. (It still _uses_ a pre-existing self.connection.)
* AdminEmailHandler.connection() method. (Init now raises an error if a
subclass has attempted to override it.)
Thanks to Natalia Bidart for shepherding DEP 0018 and for extensive
reviews and suggestions on the implementation.
Thanks to Jacob Rief for the initial implementation and multiple
iterations while refining the design.
Co-authored-by: Jacob Rief <jacob.rief@gmail.com>
|
|
Added missing test to verify Django's test runner swaps in the locmem
EmailBackend during tests.
Extracted reusable mock_test_state() helper from
SetupTestEnvironmentTests.test_allowed_hosts().
|
|
streaming responses.
|
|
|
|
https://github.com/psf/black/releases/tag/26.1.0
|
|
|
|
PartialTemplate.
Previously, assertTemplateUsed only matched partial names, ignoring
the template origin. This caused assertions on partials specified by
origin ("template.html#partial") to fail. Refs #36410.
|
|
HTMLParser fixed parsing.
Further details about Python changes can be found in:
https://github.com/python/cpython/commit/0243f97cbadec8d985e63b1daec5d1cbc850cae3.
Thank you Clifford Gama for the thorough review!
|
|
Performance regression in 1dae65dc63ae84be5002c37b4ddae0b9220e8808.
Thanks to Adam Johnson for the report.
|
|
Follow up to f5df7ed7e62585c7d0289a88a327dab8d608efcf.
|
|
This was added in 46c7707e50400e237cbd774a31ad801669ca3905 but is
obsolete now that gis_tests are discovered separately. It's
error-prone to ignore mistyped names.
|
|
|
|
Avoided repeatedly templating the URL and hoisted Person creation to
setUpTestData in AssertNumQueriesContextManagerTests to repeat the same
pattern as in CaptureQueriesContextManagerTests.
|
|
|
|
|
|
|
|
TransactionTestCase.setUpClass().
|
|
|
|
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
|
|
Python 3.13+.
On SQLite, close() doesn't explicitly close in-memory connections.
Follow up to 921670c6943e9c532137b7d164885f2d3ab436b8 and
dd45d5223b3c5640baefcb591782bbcff873b6bf.
|
|
Regression in 8fb0be3500cc7519a56985b1b6f415d75ac6fedb.
Thanks Florian Apolloner for the report.
|
|
|
|
test_skip_class_unless_db_feature() test on Python 3.12.2+.
Python 3.12.2 bring back the skipped tests in the number of running
tests. Refs
https://github.com/python/cpython/commit/0a737639dcd3b7181250f5d56694b192eaddeef0
|
|
|
|
|
|
|
|
test_skip_class_unless_db_feature() test on Python 3.12.1+.
Python 3.12.1+ no longer includes skipped tests in the number of
running tests. Check out:
https://github.com/python/cpython/issues/110890#issuecomment-1763458686
https://github.com/python/cpython/pull/106588
|
|
error messages.
|
|
consistent with other assertions.
Co-authored-by: Chinmoy Chakraborty <chinmoy12c@gmail.com>
|
|
|
|
templates.
|
|
deprecation timeline.
|
|
timeline.
|
|
|
|
Black 23.1.0 is released which, as the first release of the year,
introduces the 2023 stable style. This incorporates most of last year's
preview style.
https://github.com/psf/black/releases/tag/23.1.0
|
|
|
|
name to SimpleTestCase.assertFormError()/assertFormSetError().
Per deprecation timeline.
|
|
SimpleTestCase.assertFormError()/assertFormsetErrors().
Per deprecation timeline.
|
|
|
|
AssertNumQueriesUponConnectionTests tests.
|
|
assertQuerySetEqual().
Co-Authored-By: Michael Howitz <mh@gocept.com>
|
|
assertFormSetError().
Co-Authored-By: Michael Howitz <mh@gocept.com>
|
|
transaction.on_commit().
Thanks David Wobrock and Mariusz Felisiak for reviews.
|
|
support transactions.
|
|
Python 3.11 uses fully qualified test name in unittest output. See
https://github.com/python/cpython/commit/755be9b1505af591b9f2ee424a6525b6c2b65ce9
|
|
SimpleTestCase.assertFormError()/assertFormsetErrors() to take form/formset.
Instead of taking a response object and a context name for
the form/formset, the two methods now take the object directly.
|
|
to test_utils.
This also removes redundant tests in test_client_regress.
Follow up to 68144f40490b2572c8da4341742b9e387e3f6bdd.
|
|
Following d9a266d657f66b8c4fa068408002a4e3709ee669.
|
|
Most QuerySet methods are mapped onto the Manager and, in general,
it isn't necessary to call .all() on the manager.
|
|
"field" is passed without "form_index".
|