diff --git a/tests/components/recorder/test_init.py b/tests/components/recorder/test_init.py index 238f6420c78..65f5869b6ca 100644 --- a/tests/components/recorder/test_init.py +++ b/tests/components/recorder/test_init.py @@ -142,7 +142,7 @@ async def test_shutdown_before_startup_finishes( hass.set_state(CoreState.not_running) recorder_helper.async_initialize_recorder(hass) - hass.create_task(async_setup_recorder_instance(hass, config)) + hass.async_create_task(async_setup_recorder_instance(hass, config)) await recorder_helper.async_wait_recorder(hass) instance = get_instance(hass) @@ -172,7 +172,7 @@ async def test_canceled_before_startup_finishes( """Test recorder shuts down when its startup future is canceled out from under it.""" hass.set_state(CoreState.not_running) recorder_helper.async_initialize_recorder(hass) - hass.create_task(async_setup_recorder_instance(hass)) + hass.async_create_task(async_setup_recorder_instance(hass)) await recorder_helper.async_wait_recorder(hass) instance = get_instance(hass) @@ -224,7 +224,7 @@ async def test_state_gets_saved_when_set_before_start_event( hass.set_state(CoreState.not_running) recorder_helper.async_initialize_recorder(hass) - hass.create_task(async_setup_recorder_instance(hass)) + hass.async_create_task(async_setup_recorder_instance(hass)) await recorder_helper.async_wait_recorder(hass) entity_id = "test.recorder" @@ -2509,7 +2509,7 @@ async def test_commit_before_commits_pending_writes( } recorder_helper.async_initialize_recorder(hass) - hass.create_task(async_setup_recorder_instance(hass, config)) + hass.async_create_task(async_setup_recorder_instance(hass, config)) await recorder_helper.async_wait_recorder(hass) instance = get_instance(hass) assert instance.commit_interval == 60