Just get the API key by user ID.

This commit is contained in:
george 2022-02-03 19:49:29 +00:00
parent 836e599517
commit 3837a9955e
No known key found for this signature in database
GPG Key ID: D30164B91DE6EEE3
1 changed files with 1 additions and 1 deletions

View File

@ -16,7 +16,7 @@ def test_create_delete_api_key(flask_client):
follow_redirects=True,
)
assert create_r.status_code == 200
api_key = ApiKey.get_by(user_id=user.id, name="for test")
api_key = ApiKey.get_by(user_id=user.id)
assert ApiKey.count() == 1
assert api_key.name == "for test"