test(emqx_resource_health_check): add async_create to create_local

This commit is contained in:
EMQ-YangM 2022-01-24 14:24:31 +08:00
parent 8506bed489
commit c870a2c78c
1 changed files with 3 additions and 2 deletions

View File

@ -105,8 +105,9 @@ t_healthy(_) ->
{ok, _} = emqx_resource:create_local( {ok, _} = emqx_resource:create_local(
?ID, ?ID,
?TEST_RESOURCE, ?TEST_RESOURCE,
#{name => <<"test_resource">>}), #{name => <<"test_resource">>}, #{async_create => true}),
timer:sleep(300),
emqx_resource_health_check:create_checker(?ID, 15000),
#{pid := Pid} = emqx_resource:query(?ID, get_state), #{pid := Pid} = emqx_resource:query(?ID, get_state),
ok = emqx_resource:health_check(?ID), ok = emqx_resource:health_check(?ID),