diff options
| author | Malcolm Tredinnick <malcolm.tredinnick@gmail.com> | 2008-02-03 01:37:29 +0000 |
|---|---|---|
| committer | Malcolm Tredinnick <malcolm.tredinnick@gmail.com> | 2008-02-03 01:37:29 +0000 |
| commit | f45dab306114756b4ad4a81d409af27ce02e9dee (patch) | |
| tree | 13efc2b6b7e648a034092253983c67cac3f2379c | |
| parent | 046d943148e82c4f2a9a164b6bfceb8c7dda2608 (diff) | |
Fixed #6479 -- Use settings.SESSION_COOKIE_NAME instead of hard-coded "sessionid" in the test client. Thanks, Bastian Kleineidam.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7058 bcc190cf-cafb-0310-a4f2-bffc1f526a37
| -rw-r--r-- | django/test/client.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/django/test/client.py b/django/test/client.py index bbd8239c33..b02d298418 100644 --- a/django/test/client.py +++ b/django/test/client.py @@ -262,7 +262,7 @@ class Client: self.cookies[settings.SESSION_COOKIE_NAME]['expires'] = None # Save the session values - request.session.save() + request.session.save() return True else: @@ -274,5 +274,5 @@ class Client: Causes the authenticated user to be logged out. """ session = __import__(settings.SESSION_ENGINE, {}, {}, ['']).SessionStore() - session.delete(session_key=self.cookies['sessionid'].value) + session.delete(session_key=self.cookies[settings.SESSION_COOKIE_NAME].value) self.cookies = SimpleCookie() |
