summaryrefslogtreecommitdiff
path: root/tests/test_client
AgeCommit message (Collapse)Author
2021-10-20[4.0.x] Refs #32956 -- Capitalized HTTP/HTTPS in comments, docs, and docstrings.David Smith
Backport of 7ef0bc922c0a78667ed8cbf5f85845b627ccbdf8 from main
2021-09-24[4.0.x] Fixed #33132 -- Fixed test client handling of querystring only ↵Jaap Roes
redirects. Regression in 1e5aa8e1c79252cc810af21294a6e945d11d37b3. Backport of b1bf8c8a4ba04049dc19217bf0e876488a4fae3c from main
2021-07-15Fixed #32929 -- Fixed handling query strings in AsyncRequestFactory.pochangl
2021-06-24Fixed ResourceWarning in ↵Mariusz Felisiak
test_client.tests.ClientTest.test_uploading_named_temp_file().
2021-06-23Fixed #32790 -- Ensured test Client handles redirects to domain indexes ↵tomhamiltonstubber
without a specified trailing slash.
2021-02-23Fixed #32470 -- Fixed ResolverMatch instance on test clients when ↵Marc Gibbons
request.urlconf is set.
2020-11-04Fixed #32159 -- Ensured AsyncRequestFactory correctly sets headers.Carlton Gibson
2020-11-03Fixed #32162 -- Fixed setting Content-Length header in AsyncRequestFactory.Patrick Arminio
2020-10-28Refs #25780 -- Removed redundant status code assertions from tests.Jon Dufresne
2020-10-26Simplifed formset iteration using enumerate().Jon Dufresne
2020-09-14Fixed #31789 -- Added a new headers interface to HttpResponse.Tom Carrick
2020-05-27Fixed #31494 -- Preserved query strings when following HTTP 307/308 ↵Ahmad A. Hussein
redirects in test client.
2020-05-27Refs #31494 -- Added test for query strings for GET/HEAD requests when ↵Ahmad A. Hussein
following HTTP 307/308 redirects in test client.
2020-04-28Changed django.forms.ValidationError imports to ↵François Freitag
django.core.exceptions.ValidationError. Co-Authored-By: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2020-03-18Fixed #31224 -- Added support for asynchronous views and middleware.Andrew Godwin
This implements support for asynchronous views, asynchronous tests, asynchronous middleware, and an asynchronous test client.
2019-08-11Fixed #30677 -- Improved error message for urlencode() and Client when None ↵swatantra
is passed as data.
2019-03-15Cleaned up exception message checking in some tests.Jon Dufresne
2019-02-20Fixed #18707 -- Added support for the test client to return 500 responses.Jon Dufresne
2019-01-25Fixed grammar in FakePayload exception message.Jon Dufresne
2018-12-31Updated test URL patterns to use path() and re_path().Tim Graham
2018-12-27Fixed #30024 -- Made urlencode() and Client raise TypeError when None is ↵Jon Dufresne
passed as data.
2018-11-27Made reused RequestFactory instances class attributes.Simon Charette
2018-08-25Fixed #29687 -- Allowed the test client to serialize list/tuple as JSON.Dan Palmer
2018-07-09Fixed #29553 -- Made test client set Content-Length header to a string ↵Tim Graham
rather than integer.
2018-06-20Fixed #27398 -- Added an assertion to compare URLs, ignoring the order of ↵Jan Pieter Waagmeester
their query strings.
2018-03-16Fixed hanging indentation in various code.Mariusz Felisiak
2018-02-12Added a test for Client.generic() data coercion.Tim Graham
The smart_str() call (now force_bytes()) added in e73838b6ddcc7b37c03f9eee04fa6e6a283fedb3 is otherwise untested.
2018-02-12Refs #20530 -- Added a test for test client query string encoding.Tim Graham
7bb627936034c1b9500a8d250cce75b30f980b23 is only tested in django-contrib-comments.
2018-02-06Fixed #29082 -- Allowed the test client to encode JSON request data.Nick Sarbicki
2018-02-06Fixed #27999 -- Added test client support for HTTP 307 and 308 redirects.Tom
2017-11-28Fixed #28837 -- Fixed test client crash if an exception with more than one ↵Nicolas Delaby
arg is raised. Also removed usage of the problematic pattern elsewhere. Regression in 6e55e1d88a5c4453e25f0caf7ffb68973de5c0ba.
2017-05-27Fixed #28249 -- Removed unnecessary dict.keys() calls.Jon Dufresne
iter(dict) is equivalent to iter(dict.keys()).
2017-01-25Refs #23919 -- Removed misc Python 2/3 references.Tim Graham
2017-01-19Refs #23919 -- Stopped inheriting from object to define new style classes.Simon Charette
2017-01-18Refs #23919 -- Removed most of remaining six usageClaude Paroz
Thanks Tim Graham for the review.
2017-01-18Refs #23919 -- Removed encoding preambles and future importsClaude Paroz
2016-12-12Refs #27184 -- Fixed unclosed file ResourceWarning in test_client test.Jon Dufresne
2016-12-01Fixed #27542 -- Made Client.force_login() skip auth backends without get_user().Anton Samarchyan
2016-11-14Fixed E305 flake8 warnings.Ramin Farajpour Cami
2016-11-14Decorated a few functions.Tim Graham
2016-11-10Refs #27392 -- Removed "Tests that", "Ensures that", etc. from test docstrings.za
2016-11-09Tested the test client uploading of NamedTemporaryFile.Tom Scrace
2016-11-09Fixed #27184 -- Allowed uploading TemporaryFile with the test client.Tom Scrace
Thanks Federico Capoano for finishing the patch.
2016-08-06Fixed #27027 -- Restored Client.force_login() defaulting to the first auth ↵Ben Demboski
backend.
2016-08-04Fixed #27020 -- Used a context manager to close files.Ville Skyttä
2016-06-28Replaced use of TestCase.fail() with assertRaises().Tim Graham
Also removed try/except/fail antipattern that hides exceptions.
2016-06-24Refs #17209 -- Added LoginView and LogoutView class-based viewsClaude Paroz
Thanks Tim Graham for the review.
2016-06-20Refs #26666 -- Added ALLOWED_HOSTS validation when running tests.Tobias McNulty
Also used ALLOWED_HOSTS to check for external hosts in assertRedirects().
2016-06-16Fixed #26747 -- Used more specific assertions in the Django test suite.Jon Dufresne
2016-06-02Fixed #26666 -- Added more useful error message to assertRedirectsTobias McNulty