chore: make prop pass
This commit is contained in:
parent
7c931e4dc6
commit
65eae13e0b
|
@ -31,7 +31,8 @@
|
|||
emqx_stats,
|
||||
emqx_broker,
|
||||
mria_mnesia,
|
||||
emqx_hooks
|
||||
emqx_hooks,
|
||||
emqx_config_handler
|
||||
]).
|
||||
|
||||
-define(ALL(Vars, Types, Exprs),
|
||||
|
@ -114,7 +115,9 @@ do_mock(emqx_metrics) ->
|
|||
meck:expect(emqx_metrics, all, fun() -> [{hello, 3}] end);
|
||||
do_mock(emqx_hooks) ->
|
||||
meck:expect(emqx_hooks, put, fun(_HookPoint, _MFA) -> ok end),
|
||||
meck:expect(emqx_hooks, del, fun(_HookPoint, _MF) -> ok end).
|
||||
meck:expect(emqx_hooks, del, fun(_HookPoint, _MF) -> ok end);
|
||||
do_mock(emqx_config_handler) ->
|
||||
meck:expect(emqx_config_handler, add_handler, fun(_, _) -> ok end).
|
||||
|
||||
%%--------------------------------------------------------------------
|
||||
%% MODEL
|
||||
|
|
|
@ -44,7 +44,7 @@ paths() ->
|
|||
sys(get, _Params) ->
|
||||
{200, emqx_conf:get_raw([sys_topics], #{})};
|
||||
sys(put, #{body := Body}) ->
|
||||
{ok, _} = emqx_conf:update([sys_topics], Body, #{override_to => cluster}),
|
||||
{ok, _} = emqx_conf:update([sys_topics], Body, #{override_to => cluster}),
|
||||
{200, emqx_conf:get_raw([sys_topics], #{})}.
|
||||
|
||||
%%--------------------------------------------------------------------
|
||||
|
|
Loading…
Reference in New Issue