Ejemplo n.º 1
0
def profile_with_best_friend(session, profile):
    """Registered profiles with best friend"""
    raw_password = '******'
    email = '*****@*****.**'
    p = Profile(email=email,
                password=raw_password,
                name='Profile with best friend')
    p.send_request(profile)
    profile.confirm_request(p)
    p.set_best_friend(profile)
    session.commit()
    p = Profile.get_by_email(email)
    p.raw_password = raw_password
    return p