Hello,
Is this should work?
In [1]: auth.get_or_create_user(dict(first_name='Bart',
last_name='Simpson',
username='bart',
email='ba...@simpson.com',
password='bart_password',
registration_key='bart',
registration_id=''
),
login=False)
Out[1]: <Row {'auth_event': <Set (auth_event.user_id = 1)>, 'first_name': 'Bart', 'last_name': 'Simpson', 'registration_id': '', 'id': 1L, 'reset_password_key': '', 'auth_membership': <Set (auth_membership.user_id = 1)>, 'auth_cas': <Set (auth_cas.user_id = 1)>, 'password': 'bart_password', 'registration_key': 'bart', 'email': 'ba...@simpson.com'}>
In [2]: db.commit()
In [3]: auth.login_bare('ba...@simpson.com', 'bart_password')
Out[3]: False
In [4]: db(db.auth_user.email == 'ba...@simpson.com').select()
Out[4]: <Rows (1)>
I mean I should be login bare, no?
I lost all my certainty about the auth test case related to user logged in as I found that the only way user can be logged in is that work is using
auth.get_or_create_user(login=True)
So, actual test implementation pass only because I wasn't specify login=False in the setUp() user creation... But if I specify it related test fail as they required login_bare() to succeed which is not the case...
I am in the process of refactoring the Auth test suite, but can't finish it if login_bare() won't work...
If this issue is confirmed it there at least before 2.13.4 as I try it as long as the last 2.14.4