test(retainer): fix test cases
This commit is contained in:
parent
e4b8d79444
commit
fa6d65887d
|
@ -256,6 +256,10 @@ t_wildcard_subscription(_) ->
|
||||||
ok = emqtt:disconnect(C1).
|
ok = emqtt:disconnect(C1).
|
||||||
|
|
||||||
t_message_expiry(_) ->
|
t_message_expiry(_) ->
|
||||||
|
ConfMod = fun(Conf) ->
|
||||||
|
Conf#{<<"delivery_rate">> := <<"infinity">>}
|
||||||
|
end,
|
||||||
|
Case = fun() ->
|
||||||
{ok, C1} = emqtt:start_link([{clean_start, true}, {proto_ver, v5}]),
|
{ok, C1} = emqtt:start_link([{clean_start, true}, {proto_ver, v5}]),
|
||||||
{ok, _} = emqtt:connect(C1),
|
{ok, _} = emqtt:connect(C1),
|
||||||
|
|
||||||
|
@ -310,7 +314,9 @@ t_message_expiry(_) ->
|
||||||
emqtt:publish(C1, <<"retained/3">>, <<"">>, [{qos, 0}, {retain, true}]),
|
emqtt:publish(C1, <<"retained/3">>, <<"">>, [{qos, 0}, {retain, true}]),
|
||||||
emqtt:publish(C1, <<"$SYS/retained/4">>, <<"">>, [{qos, 0}, {retain, true}]),
|
emqtt:publish(C1, <<"$SYS/retained/4">>, <<"">>, [{qos, 0}, {retain, true}]),
|
||||||
|
|
||||||
ok = emqtt:disconnect(C1).
|
ok = emqtt:disconnect(C1)
|
||||||
|
end,
|
||||||
|
with_conf(ConfMod, Case).
|
||||||
|
|
||||||
t_message_expiry_2(_) ->
|
t_message_expiry_2(_) ->
|
||||||
ConfMod = fun(Conf) ->
|
ConfMod = fun(Conf) ->
|
||||||
|
@ -410,6 +416,7 @@ t_flow_control(_) ->
|
||||||
JsonCfg = make_limiter_json(<<"1/1s">>),
|
JsonCfg = make_limiter_json(<<"1/1s">>),
|
||||||
emqx_limiter_server:add_bucket(emqx_retainer, internal, LimiterCfg),
|
emqx_limiter_server:add_bucket(emqx_retainer, internal, LimiterCfg),
|
||||||
emqx_retainer:update_config(#{
|
emqx_retainer:update_config(#{
|
||||||
|
<<"delivery_rate">> => <<"1/1s">>,
|
||||||
<<"flow_control">> =>
|
<<"flow_control">> =>
|
||||||
#{
|
#{
|
||||||
<<"batch_read_number">> => 1,
|
<<"batch_read_number">> => 1,
|
||||||
|
|
Loading…
Reference in New Issue