File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
custom_components/calendar_event Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -114,7 +114,7 @@ async def _update_state(self) -> None:
114114 self ._attr_is_on = False
115115 self ._attr_extra_state_attributes .update (
116116 {
117- ATTR_DESCRIPTION : None ,
117+ ATTR_DESCRIPTION : "" ,
118118 }
119119 )
120120 self .async_write_ha_state ()
@@ -132,7 +132,7 @@ async def _update_state(self) -> None:
132132 self ._attr_is_on = False
133133 self ._attr_extra_state_attributes .update (
134134 {
135- ATTR_DESCRIPTION : None ,
135+ ATTR_DESCRIPTION : "" ,
136136 }
137137 )
138138
Original file line number Diff line number Diff line change @@ -130,7 +130,7 @@ async def test_binary_sensor_matching_criteria(
130130 )
131131 else :
132132 assert binary_sensor_state .state == "off"
133- assert binary_sensor_state .attributes .get (ATTR_DESCRIPTION ) is None
133+ assert binary_sensor_state .attributes .get (ATTR_DESCRIPTION ) == ""
134134
135135
136136async def test_binary_sensor_no_events (
@@ -172,7 +172,7 @@ async def test_binary_sensor_no_events(
172172 binary_sensor_state = hass .states .get (binary_sensor_entity_id )
173173 assert binary_sensor_state is not None
174174 assert binary_sensor_state .state == "off"
175- assert binary_sensor_state .attributes .get (ATTR_DESCRIPTION ) is None
175+ assert binary_sensor_state .attributes .get (ATTR_DESCRIPTION ) == ""
176176
177177
178178async def test_binary_sensor_calendar_unavailable (
@@ -205,7 +205,7 @@ async def test_binary_sensor_calendar_unavailable(
205205 binary_sensor_state = hass .states .get (binary_sensor_entity_id )
206206 assert binary_sensor_state is not None
207207 assert binary_sensor_state .state == "off"
208- assert binary_sensor_state .attributes .get (ATTR_DESCRIPTION ) is None
208+ assert binary_sensor_state .attributes .get (ATTR_DESCRIPTION ) == ""
209209
210210
211211async def test_binary_sensor_state_change_listener (
You can’t perform that action at this time.
0 commit comments