feat(agent): add redis short-term user context cache and align tests
This commit is contained in:
@@ -38,10 +38,6 @@ class FakeUserService:
|
||||
bio=update.bio if update.bio is not None else self._user.bio,
|
||||
)
|
||||
|
||||
async def get_by_username(self, username: str) -> UserResponse:
|
||||
return self._user
|
||||
|
||||
|
||||
def _find_free_port() -> int:
|
||||
with socket.socket(socket.AF_INET, socket.SOCK_STREAM) as sock:
|
||||
sock.bind(("127.0.0.1", 0))
|
||||
@@ -99,10 +95,6 @@ def test_profile_flow_e2e() -> None:
|
||||
)
|
||||
assert updated.status == 200
|
||||
assert updated.json()["username"] == "updated"
|
||||
|
||||
public = request_context.get("/api/v1/users/demo")
|
||||
assert public.status == 200
|
||||
assert public.json()["username"] == "demo"
|
||||
finally:
|
||||
request_context.dispose()
|
||||
finally:
|
||||
|
||||
Reference in New Issue
Block a user