summaryrefslogtreecommitdiff
path: root/docs/topics/testing
AgeCommit message (Collapse)Author
2026-06-15Fixed password hashing anchor link for references.Tim Schilling
2026-06-15Fixed #37128 -- Doc'd setUpTestData as test speed up.Tim Schilling
Revises the AnimalTestCase to better show test data isolation and avoid the opportunity to use setUpTestData.
2026-06-11Fixed #36837 -- Skipped backends not implementing (a)get_user() in ↵Sezer BOZKIR
(a)force_login(). Co-authored-by: Mykhailo Havelia <Arfey17.mg@gmail.com>
2026-05-20Refs #35514 -- Cleaned up mailers docs.Mike Edmunds
* Fixed typos related to automated EMAIL_PROVIDERS -> MAILERS renaming. * Clarified wording in some recently added/updated sections. * Removed deprecated, extraneous `fail_silently=False` from examples. * Moved EmailBackend API documentation out of "Email backends" intro into a dedicated section in email.txt. * Sorted MAILERS alphabetically in settings.txt.
2026-05-13Fixed #35514 -- Implemented dictionary-based MAILERS.Mike Edmunds
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>
2026-04-24Replaced references in docs to accepted PEPs with specific Python docs links.Mike Edmunds
Where the docs used `:pep:` links for established Python language features, replaced them with direct references to the Python docs (usually glossary terms).
2025-10-29Fixed #36329 -- Removed non-code custom link text when cross-referencing ↵Clifford Gama
Python objects. Thanks Bruno Alla, Sarah Boyce, and Jacob Walls for reviews. Co-authored-by: Sarah Boyce <42296566+sarahboyce@users.noreply.github.com>
2025-09-17Removed versionadded/changed annotations for 5.2.Jacob Walls
2025-08-28Ensured :doc: role uses absolute targets in docs.Adam Johnson
2025-08-28Fixed #36570 -- Removed unnecessary :py domain from documentation roles.SaJH
Signed-off-by: SaJH <wogur981208@gmail.com>
2025-08-25Refs #36485 -- Rewrapped docs to 79 columns line length.David Smith
Lines in the docs files were manually adjusted to conform to the 79 columns limit per line (plus newline), improving readability and consistency across the content.
2025-08-25Refs #36485 -- Removed double spaces after periods in sentences.Natalia
2025-08-25Refs #36485 -- Removed unnecessary parentheses in :meth: and :func: roles in ↵David Smith
docs.
2025-08-04Corrected assertNumQueries() example in docs/topics/testing/tools.txt.Adam Zapletal
2025-04-15Fixed #36311 -- Unified spelling of "hardcode" and its variants in docs.Ahmed Nassar
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
2025-02-16Refs #35967 -- Deprecated BaseDatabaseCreation.create_test_db(serialize).Simon Charette
Given there are no longer any internal usages of serialize=True and it poses a risk to non-test databases integrity it seems appropriate to deprecate it.
2025-02-16Refs #35967 -- Doc'd DatabaseCreation.serialize_db_to_string() method.Simon Charette
2025-01-28Refs #36005 -- Bumped minimum supported versions of 3rd-party packages.Mariusz Felisiak
This bumps minimum supported versions of 3rd-party packages to the first releases to support Python 3.12.
2025-01-20Fixed #36005 -- Dropped support for Python 3.10 and 3.11.Mariusz Felisiak
2025-01-15Removed versionadded/changed annotations for 5.1.Sarah Boyce
This also removes remaining versionadded/changed annotations for older versions.
2024-12-16Fixed #36008 -- Fixed order of database reset in TransactionTestCase docs.Chiemezuo
2024-09-17Fixed #35660 -- Made serialized_rollback and fixture data available in ↵Jacob Walls
TransactionTestCase.setUpClass().
2024-05-22Removed versionadded/changed annotations for 5.0.Natalia
This also removes remaining versionadded/changed annotations for older versions.
2024-03-06Fixed broken links and redirects in docs.Mariusz Felisiak
2024-01-26Applied Black's 2024 stable style.Mariusz Felisiak
https://github.com/psf/black/releases/tag/24.1.0
2024-01-09Made management command examples more consistent in docs.evananyonga
2023-12-22Fixed #34658 -- Added SimpleTestCase.assertNotInHTML().Nicolas Lupien
2023-11-23Fixed #14611 -- Added query_params argument to RequestFactory and Client ↵Tom Carrick
classes.
2023-10-03Fixed #34657 -- Made assert(Not)Contains/assertInHTML display haystacks in ↵Chinmoy Chakraborty
error messages.
2023-10-02Fixed #32602 -- Clarified wording of TestCase class.faishalmanzar
2023-09-29Refs #15667 -- Added resetting default renderer when FORM_RENDERER is changed.Mariusz Felisiak
2023-09-18Refs #26029 -- Removed DEFAULT_FILE_STORAGE and STATICFILES_STORAGE settings.Mariusz Felisiak
This also removes django.core.files.storage.get_storage_class(). Per deprecation timeline.
2023-09-18Refs #33990 -- Removed TransactionTestCase.assertQuerysetEqual() per ↵Mariusz Felisiak
deprecation timeline.
2023-09-18Refs #33990 -- Removed SimpleTestCase.assertFormsetError() per deprecation ↵Mariusz Felisiak
timeline.
2023-09-18Removed versionadded/changed annotations for 4.2.Mariusz Felisiak
This also removes remaining versionadded/changed annotations for older versions.
2023-08-31Fixed #34210 -- Added unittest's durations option to the test runner.David Smith
2023-08-30Fixed #34757 -- Added support for following redirects to AsyncClient.Olivier Tabone
2023-08-24Avoided counting exceptions in AsyncClient docs.Mariusz Felisiak
Follow up to ad6bb20557f5c87de26aeb3afb061af942a8cc17.
2023-06-27Fixed #34391 -- Added async-compatible interface to auth functions and ↵Jon Janzen
related methods test clients.
2023-06-26Refs #34233 -- Bumped minimum supported version of Selenium to 4.8.0.Mariusz Felisiak
This bumps minimum supported versions of selenium to the first release to support Python 3.10.
2023-06-13Refs #30220 -- Bumped required version of Selenium to 3.8.0.Mariusz Felisiak
Follow up to 8d010f39869f107820421631111417298d1c5bb9.
2023-04-17Used extlinks for PyPI links.Tim Graham
Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2023-03-01Fixed #34140 -- Reformatted code blocks in docs with blacken-docs.django-bot
2023-03-01Refs #34140 -- Made minor edits to rst code-blocks.Mariusz Felisiak
2023-02-28Refs #34140 -- Corrected rst code-block and various formatting issues in docs.Joseph Victor Zammit
2023-02-10Refs #34140 -- Applied rst code-block to non-Python examples.Carlton Gibson
Thanks to J.V. Zammit, Paolo Melchiorre, and Mariusz Felisiak for reviews.
2023-01-31Fixed #34180 -- Added note about resetting language in test tear-downs.Durval Carvalho
Co-authored-by: Faris Naimi <farisfaris66@gmail.com>
2023-01-17Refs #33348 -- Removed support for passing response object and form/formset ↵Mariusz Felisiak
name to SimpleTestCase.assertFormError()/assertFormSetError(). Per deprecation timeline.
2023-01-17Refs #32655 -- Removed extra_tests argument for ↵Mariusz Felisiak
DiscoverRunner.build_suite()/run_tests(). Per deprecation timeline.
2023-01-17Refs #32446 -- Removed SERIALIZE test database setting per deprecation timeline.Mariusz Felisiak