mirror of
https://github.com/home-assistant/core.git
synced 2025-04-24 17:27:52 +00:00
Verify that we register blueprints on automation setup (#43434)
This commit is contained in:
parent
bbb82ded68
commit
dc5f7aedd7
@ -163,6 +163,9 @@ async def async_setup(hass, config):
|
||||
"""Set up the automation."""
|
||||
hass.data[DOMAIN] = component = EntityComponent(LOGGER, DOMAIN, hass)
|
||||
|
||||
# To register the automation blueprints
|
||||
async_get_blueprints(hass)
|
||||
|
||||
await _async_process_config(hass, config, component)
|
||||
|
||||
async def trigger_service_handler(entity, service_call):
|
||||
|
@ -3,7 +3,6 @@ from pathlib import Path
|
||||
|
||||
import pytest
|
||||
|
||||
from homeassistant.components import automation
|
||||
from homeassistant.setup import async_setup_component
|
||||
|
||||
from tests.async_mock import Mock, patch
|
||||
@ -15,7 +14,7 @@ async def setup_bp(hass):
|
||||
assert await async_setup_component(hass, "blueprint", {})
|
||||
|
||||
# Trigger registration of automation blueprints
|
||||
automation.async_get_blueprints(hass)
|
||||
await async_setup_component(hass, "automation", {})
|
||||
|
||||
|
||||
async def test_list_blueprints(hass, hass_ws_client):
|
||||
|
Loading…
x
Reference in New Issue
Block a user