Esempio n. 1
0
def test_from_str_bad_type(app):
    """from_str does not return a user for a token with a bogus typ"""
    tok = FakeSerializer.dumps({'iss': 'ra2', 'typ': 'booogus'})
    with app.app_context():
        eq_(loader.token_loader.from_str(tok), None)
Esempio n. 2
0
def test_from_str_bad_type(app):
    """from_str does not return a user for a token with a bogus typ"""
    tok = FakeSerializer.dumps({'iss': 'ra2', 'typ': 'booogus'})
    with app.app_context():
        eq_(loader.token_loader.from_str(tok), None)
Esempio n. 3
0
def test_from_str_no_type(app):
    """from_str does not return a user for a token with no 'typ'"""
    tok = FakeSerializer.dumps({})
    with app.app_context():
        eq_(loader.token_loader.from_str(tok), None)
Esempio n. 4
0
def test_from_str_no_type(app):
    """from_str does not return a user for a token with no 'typ'"""
    tok = FakeSerializer.dumps({})
    with app.app_context():
        eq_(loader.token_loader.from_str(tok), None)