fix: Lint fixes of core and repositories tests
All checks were successful
Backend CI / lint (push) Successful in 9m26s
Backend CI / test (push) Successful in 4m24s

This commit is contained in:
JSC
2025-08-01 09:17:20 +02:00
parent 389cfe2d6a
commit dc29915fbc
8 changed files with 135 additions and 88 deletions

View File

@@ -1,4 +1,5 @@
"""Tests for user repository."""
# ruff: noqa: ARG002
from collections.abc import AsyncGenerator
@@ -174,24 +175,24 @@ class TestUserRepository:
test_user: User,
) -> None:
"""Test updating a user."""
UPDATED_CREDITS = 200
updated_credits = 200
update_data = {
"name": "Updated Name",
"credits": UPDATED_CREDITS,
"credits": updated_credits,
}
updated_user = await user_repository.update(test_user, update_data)
assert updated_user.id == test_user.id
assert updated_user.name == "Updated Name"
assert updated_user.credits == UPDATED_CREDITS
assert updated_user.credits == updated_credits
assert updated_user.email == test_user.email # Unchanged
@pytest.mark.asyncio
async def test_delete_user(
self,
user_repository: UserRepository,
ensure_plans: tuple[Plan, Plan], # noqa: ARG002
ensure_plans: tuple[Plan, Plan],
test_session: AsyncSession,
) -> None:
"""Test deleting a user."""