diff --git a/test/emqx_connection_SUITE.erl b/test/emqx_connection_SUITE.erl index 822194443..e0da75fed 100644 --- a/test/emqx_connection_SUITE.erl +++ b/test/emqx_connection_SUITE.erl @@ -93,7 +93,7 @@ t_info(_) -> {'$gen_call', From, info} -> gen_server:reply(From, emqx_connection:info(st())) after - 0 -> error("error") + 200 -> error("error") end end), #{sockinfo := SockInfo} = emqx_connection:info(CPid), diff --git a/test/emqx_mod_presence_SUITE.erl b/test/emqx_mod_presence_SUITE.erl index afa7a4312..49d5d206b 100644 --- a/test/emqx_mod_presence_SUITE.erl +++ b/test/emqx_mod_presence_SUITE.erl @@ -63,17 +63,17 @@ recv_and_check_presence(ClientId, Presence) -> binary:split(Topic, <<"/">>, [global])), case Presence of <<"connected">> -> - ?assertMatch(#{clientid := <<"clientid">>, - username := <<"username">>, - ipaddress := <<"127.0.0.1">>, - proto_name := <<"MQTT">>, - proto_ver := ?MQTT_PROTO_V4, - connack := ?RC_SUCCESS, - clean_start := true}, emqx_json:decode(Payload, [{labels, atom}, return_maps])); + ?assertMatch(#{<<"clientid">> := <<"clientid">>, + <<"username">> := <<"username">>, + <<"ipaddress">> := <<"127.0.0.1">>, + <<"proto_name">> := <<"MQTT">>, + <<"proto_ver">> := ?MQTT_PROTO_V4, + <<"connack">> := ?RC_SUCCESS, + <<"clean_start">> := true}, emqx_json:decode(Payload, [return_maps])); <<"disconnected">> -> - ?assertMatch(#{clientid := <<"clientid">>, - username := <<"username">>, - reason := <<"normal">>}, emqx_json:decode(Payload, [{labels, atom}, return_maps])) + ?assertMatch(#{<<"clientid">> := <<"clientid">>, + <<"username">> := <<"username">>, + <<"reason">> := <<"normal">>}, emqx_json:decode(Payload, [return_maps])) end. %%--------------------------------------------------------------------