Commit 23c7ac2c authored by Luna's avatar Luna 😻

test_admin_api.test_users: properly delete test users

parent 2c7c313a
Pipeline #60776073 passed with stage
in 9 minutes and 23 seconds
......@@ -84,8 +84,12 @@ async def _del_user(test_cli, user_id, *, token=None):
assert rjson['new']['id'] == user_id
assert rjson['old']['id'] == rjson['new']['id']
# TODO: remove from database at this point? it'll just keep being
# filled up every time we run a test..
# delete the original record since the DELETE endpoint will just
# replace the user by a "Deleted User <random hex>", and we don't want
# to have obsolete users filling up our db every time we run tests
await test_cli.app.db.execute("""
DELETE FROM users WHERE id = $1
""", int(user_id))
@pytest.mark.asyncio
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment