mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 21:27:38 +00:00
Remove deprecated yaml import for waze_travel_time (#80669)
Remove deprecated yaml import Signed-off-by: Kevin Stillhammer <kevin.stillhammer@gmail.com> Signed-off-by: Kevin Stillhammer <kevin.stillhammer@gmail.com>
This commit is contained in:
parent
da14acb3b6
commit
8dd2d6f825
@ -134,5 +134,3 @@ class ConfigFlow(config_entries.ConfigFlow, domain=DOMAIN):
|
||||
),
|
||||
errors=errors,
|
||||
)
|
||||
|
||||
async_step_import = async_step_user
|
||||
|
@ -101,47 +101,6 @@ async def test_options(hass):
|
||||
}
|
||||
|
||||
|
||||
@pytest.mark.usefixtures("validate_config_entry")
|
||||
async def test_import(hass):
|
||||
"""Test import for config flow."""
|
||||
result = await hass.config_entries.flow.async_init(
|
||||
DOMAIN,
|
||||
context={"source": config_entries.SOURCE_IMPORT},
|
||||
data={
|
||||
CONF_ORIGIN: "location1",
|
||||
CONF_DESTINATION: "location2",
|
||||
CONF_REGION: "US",
|
||||
CONF_AVOID_FERRIES: True,
|
||||
CONF_AVOID_SUBSCRIPTION_ROADS: True,
|
||||
CONF_AVOID_TOLL_ROADS: True,
|
||||
CONF_EXCL_FILTER: "exclude",
|
||||
CONF_INCL_FILTER: "include",
|
||||
CONF_REALTIME: False,
|
||||
CONF_UNITS: CONF_UNIT_SYSTEM_IMPERIAL,
|
||||
CONF_VEHICLE_TYPE: "taxi",
|
||||
},
|
||||
)
|
||||
|
||||
assert result["type"] == data_entry_flow.FlowResultType.CREATE_ENTRY
|
||||
await hass.async_block_till_done()
|
||||
entry = hass.config_entries.async_entries(DOMAIN)[0]
|
||||
assert entry.data == {
|
||||
CONF_ORIGIN: "location1",
|
||||
CONF_DESTINATION: "location2",
|
||||
CONF_REGION: "US",
|
||||
}
|
||||
assert entry.options == {
|
||||
CONF_AVOID_FERRIES: True,
|
||||
CONF_AVOID_SUBSCRIPTION_ROADS: True,
|
||||
CONF_AVOID_TOLL_ROADS: True,
|
||||
CONF_EXCL_FILTER: "exclude",
|
||||
CONF_INCL_FILTER: "include",
|
||||
CONF_REALTIME: False,
|
||||
CONF_UNITS: CONF_UNIT_SYSTEM_IMPERIAL,
|
||||
CONF_VEHICLE_TYPE: "taxi",
|
||||
}
|
||||
|
||||
|
||||
@pytest.mark.usefixtures("validate_config_entry")
|
||||
async def test_dupe(hass):
|
||||
"""Test setting up the same entry data twice is OK."""
|
||||
|
Loading…
x
Reference in New Issue
Block a user