ソースを参照

try to fix pytest

Falko Schindler 1 年間 前
コミット
d0f22d0a44
1 ファイル変更1 行追加0 行削除
  1. 1 0
      tests/test_storage.py

+ 1 - 0
tests/test_storage.py

@@ -89,6 +89,7 @@ async def test_access_user_storage_from_fastapi(screen: Screen):
         response = await http_client.get(f'http://localhost:{PORT}/api')
         assert response.status_code == 200
         assert response.text == '"OK"'
+        await asyncio.sleep(0.5)  # wait for storage to be written
         assert next(Path('.nicegui').glob('storage_user_*.json')).read_text() == '{"msg": "yes"}'