@@ -299,12 +299,12 @@ async def test_ezsp_connect_failure(disconnect_mock, reset_mock, version_mock):
299299 await ezsp .connect ()
300300
301301 assert conn_mock .await_count == 1
302- assert reset_mock .await_count == 5
303- assert version_mock .await_count == 5
302+ assert reset_mock .await_count == 3
303+ assert version_mock .await_count == 3
304304 assert disconnect_mock .call_count == 1
305305
306306
307- @pytest .mark .parametrize ("failures_before_success" , [1 , 2 , 3 , 4 ])
307+ @pytest .mark .parametrize ("failures_before_success" , [1 , 2 ])
308308@patch .object (EZSP , "disconnect" , new_callable = AsyncMock )
309309async def test_ezsp_connect_retry_success (disconnect_mock , failures_before_success ):
310310 """Test connection succeeding after N failures."""
@@ -319,7 +319,7 @@ async def startup_reset_mock():
319319 with patch ("bellows.uart.connect" ):
320320 ezsp = make_ezsp (version = 4 )
321321
322- with patch .object (ezsp , "startup_reset " , side_effect = startup_reset_mock ):
322+ with patch .object (ezsp , "_startup_reset " , side_effect = startup_reset_mock ):
323323 await ezsp .connect ()
324324
325325 assert call_count == failures_before_success + 1
0 commit comments