mirror of
https://github.com/django/django.git
synced 2025-08-03 18:38:50 +00:00
Fixed #29471 -- Added 'Vary: Cookie' to invalid/empty session cookie responses.
This commit is contained in:
parent
d64808cacd
commit
dc740dde50
3 changed files with 5 additions and 0 deletions
|
@ -748,6 +748,9 @@ class SessionMiddlewareTests(TestCase):
|
|||
),
|
||||
str(response.cookies[settings.SESSION_COOKIE_NAME])
|
||||
)
|
||||
# SessionMiddleware sets 'Vary: Cookie' to prevent the 'Set-Cookie'
|
||||
# from being cached.
|
||||
self.assertEqual(response['Vary'], 'Cookie')
|
||||
|
||||
@override_settings(SESSION_COOKIE_DOMAIN='.example.local', SESSION_COOKIE_PATH='/example/')
|
||||
def test_session_delete_on_end_with_custom_domain_and_path(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue