|
22 | 22 | TEST_RANDOM = 23 |
23 | 23 |
|
24 | 24 |
|
25 | | -@pytest.fixture |
26 | | -def auto_deterministic_message_fixtures(deterministic_message_fixtures: None) -> None: |
27 | | - """Auto-use deterministic message fixtures for all tests in this module.""" |
28 | | - pass |
29 | | - |
30 | | - |
31 | 25 | @pytest.fixture(name="mock_create_local_connection") |
32 | 26 | def create_local_connection_fixture( |
33 | 27 | request_handler: RequestHandler, log: CapturedRequestLog |
@@ -74,7 +68,7 @@ def build_raw_response( |
74 | 68 | connect_nonce: int | None = None, |
75 | 69 | ack_nonce: int | None = None, |
76 | 70 | ) -> bytes: |
77 | | - """Build an encoded RPC response message.""" |
| 71 | + """Build an encoded response message.""" |
78 | 72 | message = RoborockMessage( |
79 | 73 | protocol=protocol, |
80 | 74 | random=23, |
@@ -179,7 +173,14 @@ async def test_l01_session( |
179 | 173 | log: CapturedRequestLog, |
180 | 174 | snapshot: syrupy.SnapshotAssertion, |
181 | 175 | ) -> None: |
182 | | - """Test connecting to a device that speaks the L01 protocol..""" |
| 176 | + """Test connecting to a device that speaks the L01 protocol. |
| 177 | + |
| 178 | + Note that this test currently has a delay because the actual local client |
| 179 | + will delay before retrying with L01 after a failed 1.0 attempt. This should |
| 180 | + also be improved in the actual client itself, but likely requires a closer |
| 181 | + look at the actual device response in that scenario or moving to a serial |
| 182 | + request/response behavior rather than publish/subscribe. |
| 183 | + """ |
183 | 184 | # Client first attempts 1.0 and we reply with a fake invalid response. The |
184 | 185 | # response is arbitrary, and this could be improved by capturing a real L01 |
185 | 186 | # device response to a 1.0 message. |
|
0 commit comments