Permalink
Browse files

fix tests

  • Loading branch information...
vangheem committed Mar 26, 2012
1 parent dd52ee5 commit 39b7cd72eba929abdd2428cb69d51a6f364753dd
Showing with 7 additions and 5 deletions.
  1. +4 −4 factored/auth.py
  2. +3 −1 factored/tests/test_auth.py
View
@@ -37,13 +37,13 @@ def getFactoredPlugin(name):
class UsernameSchema(BaseSchema):
username = validators.MinLength(3, not_empty=True)
- referrer = validators.MinLength(0)
+ referrer = validators.UnicodeString(if_missing=u'')
class CodeSchema(BaseSchema):
username = validators.MinLength(3, not_empty=True)
code = validators.MinLength(4, not_empty=True)
- referrer = validators.MinLength(0)
+ referrer = validators.UnicodeString(if_missing=u'')
class BaseAuthView(object):
@@ -197,13 +197,13 @@ def check_code(self, user):
class EmailAuthSchema(BaseSchema):
username = validators.Email(not_empty=True)
- referrer = validators.MinLength(0)
+ referrer = validators.UnicodeString(if_missing=u'')
class EmailAuthCodeSchema(BaseSchema):
username = validators.Email(not_empty=True)
code = validators.MinLength(8, not_empty=True)
- referrer = validators.MinLength(0)
+ referrer = validators.UnicodeString(if_missing=u'')
class EmailAuthView(BaseAuthView):
@@ -58,7 +58,9 @@ def get_request(self, *args, **kwargs):
'body': "You're temporary access code is: {code}"},
'auth_tkt': auth_tkt,
'email_auth_window': 120,
- 'static_path': '/auth/static'
+ 'static_path': '/auth/static',
+ 'allowgooglecodereminder_settings': {},
+ 'allowgooglecodereminder': False
}
req.environ['who_api'] = APIFactory(
[('auth_tkt', auth_tkt)],

0 comments on commit 39b7cd7

Please sign in to comment.