mirror of
https://github.com/home-assistant/core.git
synced 2025-12-24 12:59:34 +00:00
On removal, only unload config entry if loaded (#16844)
* On removal, only unload config entry if loaded * Fix test
This commit is contained in:
@@ -72,7 +72,7 @@ def test_get_entries(hass, client):
|
||||
@asyncio.coroutine
|
||||
def test_remove_entry(hass, client):
|
||||
"""Test removing an entry via the API."""
|
||||
entry = MockConfigEntry(domain='demo')
|
||||
entry = MockConfigEntry(domain='demo', state=core_ce.ENTRY_STATE_LOADED)
|
||||
entry.add_to_hass(hass)
|
||||
resp = yield from client.delete(
|
||||
'/api/config/config_entries/entry/{}'.format(entry.entry_id))
|
||||
|
||||
Reference in New Issue
Block a user