mirror of
https://github.com/simple-login/app.git
synced 2025-02-20 22:02:54 +08:00
fix test
This commit is contained in:
parent
ed11363b0c
commit
91d5d1c9ac
2 changed files with 4 additions and 2 deletions
|
@ -160,7 +160,8 @@ class User(db.Model, ModelMixin, UserMixin):
|
|||
|
||||
if password:
|
||||
user.set_password(password)
|
||||
db.session.flush()
|
||||
|
||||
db.session.flush()
|
||||
|
||||
# create a first alias mail to show user how to use when they login
|
||||
GenEmail.create_new(user.id, prefix="my-first-alias")
|
||||
|
|
|
@ -39,8 +39,9 @@ def test_construct_url():
|
|||
def test_authorize_page_non_login_user(flask_client):
|
||||
"""make sure to display login page for non-authenticated user"""
|
||||
user = User.create("test@test.com", "test user")
|
||||
client = Client.create_new("test client", user.id)
|
||||
db.session.commit()
|
||||
|
||||
client = Client.create_new("test client", user.id)
|
||||
db.session.commit()
|
||||
|
||||
r = flask_client.get(
|
||||
|
|
Loading…
Reference in a new issue