mirror of
https://github.com/django/django.git
synced 2025-08-03 10:34:04 +00:00
Fixed #18924 -- Made test.Client.logout send user_logged_out signal.
Thanks awsum for the suggestion and Pavel Ponomarev and Florian Hahn for the patch.
This commit is contained in:
parent
e71b63e280
commit
a35ed20241
5 changed files with 102 additions and 7 deletions
|
@ -623,6 +623,10 @@ Miscellaneous
|
|||
raises NoReverseMatch. There is no change to {% url %} tag, it causes
|
||||
template rendering to fail like always when NoReverseMatch is risen.
|
||||
|
||||
* :meth:`django.test.client.Client.logout` now calls
|
||||
:meth:`django.contrib.auth.logout` which will send the
|
||||
:func:`~django.contrib.auth.signals.user_logged_out` signal.
|
||||
|
||||
Features deprecated in 1.6
|
||||
==========================
|
||||
|
||||
|
|
|
@ -696,7 +696,7 @@ Use the ``django.test.client.Client`` class to make requests.
|
|||
|
||||
After you call this method, the test client will have all the cookies
|
||||
and session data cleared to defaults. Subsequent requests will appear
|
||||
to come from an AnonymousUser.
|
||||
to come from an :class:`~django.contrib.auth.models.AnonymousUser`.
|
||||
|
||||
Testing responses
|
||||
~~~~~~~~~~~~~~~~~
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue