tests.conftest: use app_context for delete_user call

- admin_api.users: remove app arg passing
This commit is contained in:
Luna 2019-10-25 08:51:52 -03:00
parent f54c002a31
commit b0ef3c4d0c
2 changed files with 3 additions and 2 deletions

View File

@ -145,5 +145,5 @@ async def patch_user(user_id: int):
user_id,
)
public_user, _ = await mass_user_update(user_id, app)
public_user, _ = await mass_user_update(user_id)
return jsonify(public_user)

View File

@ -93,7 +93,8 @@ async def _user_fixture_setup(app):
async def _user_fixture_teardown(app, udata: dict):
await delete_user(udata["id"], app_=app)
async with app.app_context():
await delete_user(udata["id"])
@pytest.fixture(name="test_user")