mirror of
https://github.com/home-assistant/core.git
synced 2025-12-24 21:06:19 +00:00
@@ -77,7 +77,7 @@ async def test_init_accepts_and_migrates_old_entry(aioclient_mock, hass):
|
||||
|
||||
# Add original entry
|
||||
original_entry = MockConfigEntry(
|
||||
domain=DOMAIN,
|
||||
domain="homewizard_energy",
|
||||
data={CONF_IP_ADDRESS: "1.2.3.4"},
|
||||
entry_id="old_id",
|
||||
)
|
||||
@@ -122,6 +122,9 @@ async def test_init_accepts_and_migrates_old_entry(aioclient_mock, hass):
|
||||
)
|
||||
imported_entry.add_to_hass(hass)
|
||||
|
||||
assert imported_entry.domain == DOMAIN
|
||||
assert imported_entry.domain != original_entry.domain
|
||||
|
||||
# Add the entry_id to trigger migration
|
||||
with patch(
|
||||
"aiohwenergy.HomeWizardEnergy",
|
||||
|
||||
Reference in New Issue
Block a user