mirror of
https://github.com/tiqi-group/pydase.git
synced 2026-11-24 14:17:58 +01:00
fixes device connection test
This commit is contained in:
1 parent
e422d627af
commit
e88965b69d
1 file changed
+2
-2
@@ -3,6 +3,7 @@ import asyncio
|
||||
import pydase
|
||||
import pydase.components.device_connection
|
||||
import pytest
|
||||
from pydase.task.autostart import autostart_service_tasks
|
||||
from pytest import LogCaptureFixture
|
||||
|
||||
|
||||
@@ -19,10 +20,9 @@ async def test_reconnection(caplog: LogCaptureFixture) -> None:
|
||||
self._connected = True
|
||||
|
||||
service_instance = MyService()
|
||||
autostart_service_tasks(service_instance)
|
||||
|
||||
assert service_instance._connected is False
|
||||
|
||||
service_instance._task_manager.start_autostart_tasks()
|
||||
|
||||
await asyncio.sleep(0.01)
|
||||
assert service_instance._connected is True
|
||||
Reference in new issue
Block a user