Enable Google Assistant OnOffTrait for climate devices that support them (#18544)
* Enable Google Assistant OnOffTrait for climate devices that support them This commit enables the OnOffTrait for climate devices that have the SUPPORT_ON_OFF feature. I have tested this locally with a Sensibo device which supports ON_OFF and a nest device that does not. * Update trait.py * Add tests for onoff_climate * Add OnOff trait to climate.heatpump * Add on status to heatpump in google_assistant tests
This commit is contained in:
parent
2f07e92cc2
commit
02309cc318
4 changed files with 49 additions and 1 deletions
|
@ -204,6 +204,7 @@ def test_query_climate_request(hass_fixture, assistant_client, auth_header):
|
|||
devices = body['payload']['devices']
|
||||
assert len(devices) == 3
|
||||
assert devices['climate.heatpump'] == {
|
||||
'on': True,
|
||||
'online': True,
|
||||
'thermostatTemperatureSetpoint': 20.0,
|
||||
'thermostatTemperatureAmbient': 25.0,
|
||||
|
@ -260,6 +261,7 @@ def test_query_climate_request_f(hass_fixture, assistant_client, auth_header):
|
|||
devices = body['payload']['devices']
|
||||
assert len(devices) == 3
|
||||
assert devices['climate.heatpump'] == {
|
||||
'on': True,
|
||||
'online': True,
|
||||
'thermostatTemperatureSetpoint': -6.7,
|
||||
'thermostatTemperatureAmbient': -3.9,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue