Exemplo n.º 1
0
def test_create_user(app):
    global uuid
    global alias_id
    params = {'username': '******',
              'password': '******',
              'first_name': 'bob',
              'last_name': 'hope',
              'contact_info': '*****@*****.**',
              }
    response = app.post('/createuser', params=params, status='3*')
    redirected = response.follow()
    assert 'Please wait for your confirmation link' in redirected.body

    # pull the uuid out of the db for the next step
    user = User.by_username('user1')
    alias = user.aliases[0]
    alias_id = alias.id
    uuid = alias.uuids[0].uuid