mirror of https://gitlab.com/litecord/litecord.git
tests.conftest: use app_context for delete_user call
- admin_api.users: remove app arg passing
This commit is contained in:
parent
f54c002a31
commit
b0ef3c4d0c
|
|
@ -145,5 +145,5 @@ async def patch_user(user_id: int):
|
||||||
user_id,
|
user_id,
|
||||||
)
|
)
|
||||||
|
|
||||||
public_user, _ = await mass_user_update(user_id, app)
|
public_user, _ = await mass_user_update(user_id)
|
||||||
return jsonify(public_user)
|
return jsonify(public_user)
|
||||||
|
|
|
||||||
|
|
@ -93,7 +93,8 @@ async def _user_fixture_setup(app):
|
||||||
|
|
||||||
|
|
||||||
async def _user_fixture_teardown(app, udata: dict):
|
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")
|
@pytest.fixture(name="test_user")
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue