Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 2 additions & 12 deletions tests/components/ios/test_init.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

import pytest

from homeassistant import config_entries, data_entry_flow
from homeassistant.components import ios
from homeassistant.setup import async_setup_component

Expand All @@ -30,16 +29,7 @@ async def test_creating_entry_sets_up_sensor(hass):
"homeassistant.components.ios.sensor.async_setup_entry",
return_value=mock_coro(True),
) as mock_setup:
result = await hass.config_entries.flow.async_init(
ios.DOMAIN, context={"source": config_entries.SOURCE_USER}
)

# Confirmation form
assert result["type"] == data_entry_flow.RESULT_TYPE_FORM

result = await hass.config_entries.flow.async_configure(result["flow_id"], {})
assert result["type"] == data_entry_flow.RESULT_TYPE_CREATE_ENTRY

assert await async_setup_component(hass, ios.DOMAIN, {ios.DOMAIN: {}})
await hass.async_block_till_done()

assert len(mock_setup.mock_calls) == 1
Expand All @@ -61,7 +51,7 @@ async def test_not_configuring_ios_not_creates_entry(hass):
with patch(
"homeassistant.components.ios.async_setup_entry", return_value=mock_coro(True)
) as mock_setup:
await async_setup_component(hass, ios.DOMAIN, {})
await async_setup_component(hass, ios.DOMAIN, {"foo": "bar"})
await hass.async_block_till_done()

assert len(mock_setup.mock_calls) == 0
2 changes: 0 additions & 2 deletions tests/ignore_uncaught_exceptions.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""List of modules that have uncaught exceptions today. Will be shrunk over time."""
IGNORE_UNCAUGHT_EXCEPTIONS = [
("tests.components.ios.test_init", "test_creating_entry_sets_up_sensor"),
("tests.components.ios.test_init", "test_not_configuring_ios_not_creates_entry"),
("tests.components.local_file.test_camera", "test_file_not_readable"),
]

Expand Down