mirror of
https://github.com/home-assistant/core.git
synced 2025-12-24 12:59:34 +00:00
Allow passing None as input_text config (#26409)
This commit is contained in:
committed by
Andrew Sayre
parent
b968b53e38
commit
53720c5c48
@@ -186,3 +186,12 @@ async def test_input_text_context(hass, hass_admin_user):
|
||||
assert state2 is not None
|
||||
assert state.state != state2.state
|
||||
assert state2.context.user_id == hass_admin_user.id
|
||||
|
||||
|
||||
async def test_config_none(hass):
|
||||
"""Set up input_text without any config."""
|
||||
await async_setup_component(hass, DOMAIN, {DOMAIN: {"b1": None}})
|
||||
|
||||
state = hass.states.get("input_text.b1")
|
||||
assert state
|
||||
assert str(state.state) == "unknown"
|
||||
|
||||
Reference in New Issue
Block a user