mirror of
https://github.com/home-assistant/core.git
synced 2025-07-24 13:47:35 +00:00
Remove Shelly RSSI sensor if Wi-FI is not configured (#108390)
* Remove Shelly RSSI sensor if Wi-FI is not configured * fix tests
This commit is contained in:
parent
7fbfd44636
commit
6174aa4e59
@ -907,6 +907,9 @@ RPC_SENSORS: Final = {
|
||||
device_class=SensorDeviceClass.SIGNAL_STRENGTH,
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
entity_registry_enabled_default=False,
|
||||
removal_condition=lambda config, _status, key: (
|
||||
config[key]["sta"]["enable"] is False
|
||||
),
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
use_polling_coordinator=True,
|
||||
),
|
||||
|
@ -159,6 +159,7 @@ MOCK_CONFIG = {
|
||||
"ui_data": {},
|
||||
"device": {"name": "Test name"},
|
||||
},
|
||||
"wifi": {"sta": {"enable": True}},
|
||||
}
|
||||
|
||||
MOCK_SHELLY_COAP = {
|
||||
|
Loading…
x
Reference in New Issue
Block a user