mirror of
https://github.com/home-assistant/core.git
synced 2025-07-15 09:17:10 +00:00
Remove outdated test for locks (#143061)
Co-authored-by: Franck Nijhof <git@frenck.dev> Co-authored-by: Abílio Costa <abmantis@users.noreply.github.com>
This commit is contained in:
parent
9fb7542a6f
commit
9d02436a72
@ -6,14 +6,14 @@ from unittest.mock import MagicMock, patch
|
||||
import pytest
|
||||
import voluptuous as vol
|
||||
|
||||
from homeassistant.components import conversation, light, switch
|
||||
from homeassistant.components import light, switch
|
||||
from homeassistant.components.homeassistant.exposed_entities import async_expose_entity
|
||||
from homeassistant.const import (
|
||||
ATTR_DEVICE_CLASS,
|
||||
ATTR_FRIENDLY_NAME,
|
||||
ATTR_SUPPORTED_FEATURES,
|
||||
)
|
||||
from homeassistant.core import Context, HomeAssistant, State
|
||||
from homeassistant.core import HomeAssistant, State
|
||||
from homeassistant.helpers import (
|
||||
area_registry as ar,
|
||||
config_validation as cv,
|
||||
@ -615,25 +615,6 @@ def test_async_validate_slots_no_schema() -> None:
|
||||
}
|
||||
|
||||
|
||||
async def test_cant_turn_on_lock(hass: HomeAssistant) -> None:
|
||||
"""Test that we can't turn on entities that don't support it."""
|
||||
assert await async_setup_component(hass, "homeassistant", {})
|
||||
assert await async_setup_component(hass, "conversation", {})
|
||||
assert await async_setup_component(hass, "intent", {})
|
||||
assert await async_setup_component(hass, "lock", {})
|
||||
|
||||
hass.states.async_set(
|
||||
"lock.test", "123", attributes={ATTR_FRIENDLY_NAME: "Test Lock"}
|
||||
)
|
||||
|
||||
result = await conversation.async_converse(
|
||||
hass, "turn on test lock", None, Context(), None
|
||||
)
|
||||
|
||||
assert result.response.response_type == intent.IntentResponseType.ERROR
|
||||
assert result.response.error_code == intent.IntentResponseErrorCode.NO_VALID_TARGETS
|
||||
|
||||
|
||||
def test_async_register(hass: HomeAssistant) -> None:
|
||||
"""Test registering an intent and verifying it is stored correctly."""
|
||||
handler = MagicMock()
|
||||
|
Loading…
x
Reference in New Issue
Block a user