Forgo redirecting authentication endpoint so that login form errors can be displayed

This commit is contained in:
Matt Wright
2012-08-20 23:35:17 -04:00
parent ebe34005a1
commit bebaac49e3
7 changed files with 70 additions and 78 deletions
+2 -2
View File
@@ -35,7 +35,7 @@ class SecurityTest(TestCase):
def authenticate(self, email="matt@lp.com", password="password", endpoint=None, **kwargs):
data = dict(email=email, password=password, remember='y')
r = self._post(endpoint or '/auth', data=data, **kwargs)
r = self._post(endpoint or '/login', data=data, **kwargs)
return r
def json_authenticate(self, email="matt@lp.com", password="password", endpoint=None):
@@ -45,7 +45,7 @@ class SecurityTest(TestCase):
"password": "%s"
}
"""
return self._post(endpoint or '/auth',
return self._post(endpoint or '/login',
content_type="application/json",
data=data % (email, password))