Use TEMP_CELSIUS constant (#33963)

This commit is contained in:
springstan 2020-04-10 19:17:46 +02:00 committed by GitHub
parent ca0648afe8
commit 78d87dc40f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
24 changed files with 129 additions and 96 deletions

View file

@ -16,6 +16,7 @@ from homeassistant.const import (
ATTR_SERVICE,
EVENT_CALL_SERVICE,
EVENT_HOMEASSISTANT_STOP,
TEMP_CELSIUS,
)
from homeassistant.core import callback
from homeassistant.exceptions import ConfigEntryNotReady
@ -342,7 +343,7 @@ class TestMQTTCallbacks(unittest.TestCase):
mqtt.subscribe(self.hass, "test-topic", self.record_calls, encoding="ascii")
mqtt.subscribe(self.hass, "test-topic", self.record_calls)
fire_mqtt_message(self.hass, "test-topic", "°C")
fire_mqtt_message(self.hass, "test-topic", TEMP_CELSIUS)
self.hass.block_till_done()
assert len(self.calls) == 1