Skip to content

Commit f69f048

Browse files
committed
fix fixture
1 parent c54384b commit f69f048

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

tests/fixtures_server.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,10 @@ async def __aenter__(self):
308308
# on them from other sessions
309309
db.expunge(self.user)
310310
else:
311-
if "profile_id" not in self.user_kwargs.keys():
311+
if (
312+
self.user_kwargs is not None
313+
and "profile_id" not in self.user_kwargs.keys()
314+
):
312315
res = await db.execute(select(Profile))
313316
profile = res.scalars().one_or_none()
314317
if profile is None:

0 commit comments

Comments
 (0)