File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -501,24 +501,27 @@ async def tinker_thermostat_temp(
501501 ):
502502 """Toggle temperature to test functionality."""
503503 _LOGGER .info ("Asserting modifying settings in location (%s):" , loc_id )
504+ tinker_temp_passed = False
504505 test_temp = {"setpoint" : 22.9 }
505506 if smile ._cooling_present and not block_cooling :
506507 test_temp = {"setpoint_low" : 19.5 , "setpoint_high" : 23.5 }
507508 _LOGGER .info ("- Adjusting temperature to %s" , test_temp )
508509 try :
509510 await smile .set_temperature (loc_id , test_temp )
510511 _LOGGER .info (" + tinker_thermostat_temp worked as intended" )
511- return True
512+ tinker_temp_passed = True
512513 except (
513514 pw_exceptions .ErrorSendingCommandError ,
514515 pw_exceptions .ResponseError ,
515516 ):
516517 if unhappy :
517518 _LOGGER .info (" + tinker_thermostat_temp failed as expected" )
518- return True
519+ tinker_temp_passed = True
519520 else : # pragma: no cover
520521 _LOGGER .info (" - tinker_thermostat_temp failed unexpectedly" )
521- return True
522+ return False
523+
524+ return tinker_temp_passed
522525
523526 @pytest .mark .asyncio
524527 async def tinker_thermostat_preset (self , smile , loc_id , unhappy = False ):
You can’t perform that action at this time.
0 commit comments