Merge "Fix Django 1.7 compat"
This commit is contained in:
@@ -100,5 +100,6 @@ class Login(django_auth_forms.AuthenticationForm):
|
||||
LOG.warning(msg)
|
||||
self.request.session.flush()
|
||||
raise forms.ValidationError(exc)
|
||||
self.check_for_test_cookie()
|
||||
if hasattr(self, 'check_for_test_cookie'): # Dropped in django 1.7
|
||||
self.check_for_test_cookie()
|
||||
return self.cleaned_data
|
||||
|
||||
@@ -21,6 +21,10 @@ os.environ['DJANGO_SETTINGS_MODULE'] = 'openstack_auth.tests.settings'
|
||||
|
||||
from django.test import simple as test_simple
|
||||
|
||||
import django
|
||||
if hasattr(django, 'setup'):
|
||||
django.setup()
|
||||
|
||||
|
||||
def run(*test_args):
|
||||
if not test_args:
|
||||
|
||||
Reference in New Issue
Block a user