fix(test): flaky emqx_connector_api_SUITE test case.
This commit is contained in:
parent
977b1bb7ec
commit
0ec111d4e0
|
@ -420,8 +420,8 @@ t_mqtt_conn_update2(_) ->
|
||||||
%% we fix the 'server' parameter to a normal one, it should work
|
%% we fix the 'server' parameter to a normal one, it should work
|
||||||
{ok, 200, _} = request(put, uri(["connectors", ConnctorID]),
|
{ok, 200, _} = request(put, uri(["connectors", ConnctorID]),
|
||||||
?MQTT_CONNECOTR2(<<"127.0.0.1:1883">>)),
|
?MQTT_CONNECOTR2(<<"127.0.0.1:1883">>)),
|
||||||
{ok, 200, BridgeStr} = request(get, uri(["bridges", BridgeIDEgress]), []),
|
|
||||||
wait_for_resource_ready(BridgeIDEgress, 5),
|
wait_for_resource_ready(BridgeIDEgress, 5),
|
||||||
|
{ok, 200, BridgeStr} = request(get, uri(["bridges", BridgeIDEgress]), []),
|
||||||
?assertMatch(#{ <<"id">> := BridgeIDEgress
|
?assertMatch(#{ <<"id">> := BridgeIDEgress
|
||||||
, <<"status">> := <<"connected">>
|
, <<"status">> := <<"connected">>
|
||||||
}, jsx:decode(BridgeStr)),
|
}, jsx:decode(BridgeStr)),
|
||||||
|
|
|
@ -339,7 +339,7 @@ cluster_call(Mod, Fun, Args, Timeout) ->
|
||||||
Nodes = mria_mnesia:running_nodes(),
|
Nodes = mria_mnesia:running_nodes(),
|
||||||
{GoodRes, BadNodes} = rpc:multicall(Nodes, Mod, Fun, Args, Timeout),
|
{GoodRes, BadNodes} = rpc:multicall(Nodes, Mod, Fun, Args, Timeout),
|
||||||
BadNodes =/= [] andalso
|
BadNodes =/= [] andalso
|
||||||
?SLOG(error, #{msg => "rpc call failed", bad_nodes => BadNodes, mfa => {Mod, Fun, Args}}),
|
?SLOG(error, #{msg => "rpc_call_failed", bad_nodes => BadNodes, mfa => {Mod, Fun, Args}}),
|
||||||
GoodRes.
|
GoodRes.
|
||||||
|
|
||||||
stream_log_file(get, #{bindings := #{name := Name}, query_string := Query}) ->
|
stream_log_file(get, #{bindings := #{name := Name}, query_string := Query}) ->
|
||||||
|
|
Loading…
Reference in New Issue