diff --git a/homeassistant/components/zwave_js/binary_sensor.py b/homeassistant/components/zwave_js/binary_sensor.py index b6e27b10800..f53b670ae46 100644 --- a/homeassistant/components/zwave_js/binary_sensor.py +++ b/homeassistant/components/zwave_js/binary_sensor.py @@ -654,6 +654,7 @@ DISCOVERY_SCHEMAS: list[NewZWaveDiscoverySchema] = [ key=NOTIFICATION_SMOKE_ALARM, entity_category=EntityCategory.DIAGNOSTIC, not_states={ + 0, SmokeAlarmNotificationEvent.SENSOR_STATUS_SMOKE_DETECTED_LOCATION_PROVIDED, SmokeAlarmNotificationEvent.SENSOR_STATUS_SMOKE_DETECTED, SmokeAlarmNotificationEvent.MAINTENANCE_STATUS_REPLACEMENT_REQUIRED, diff --git a/tests/components/zwave_js/test_binary_sensor.py b/tests/components/zwave_js/test_binary_sensor.py index 5dfbb0f5bd8..b2442796466 100644 --- a/tests/components/zwave_js/test_binary_sensor.py +++ b/tests/components/zwave_js/test_binary_sensor.py @@ -383,6 +383,13 @@ async def test_smoke_co_notification_sensors( assert entity_entry assert entity_entry.entity_category == EntityCategory.DIAGNOSTIC + # Test that no idle states are created as entities + entity_id = "binary_sensor.zcombo_g_smoke_co_alarm_idle" + state = hass.states.get(entity_id) + assert state is None + entity_entry = entity_registry.async_get(entity_id) + assert entity_entry is None + # Test state updates for smoke alarm event = Event( type="value updated",