25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-20 16:15:59 +01:00

Test: Fix some minor compilation warnings

- This QueryID is unnecessary since d3aeed8, due to d6e9e03
- DB variable was added in d32a0ce to detect riak and disable some tests,
  but support for Riak was removed later in 3f7d9e3.
- MyJID was added in 5b863c2 but was never actually used
- recv2 return should be checked
This commit is contained in:
Badlop 2024-04-15 13:16:57 +02:00
parent 697e5b8b6c
commit e973360aa7
3 changed files with 3 additions and 5 deletions

View File

@ -492,7 +492,7 @@ send_query(Config, #mam_query{xmlns = NS} = Query) ->
maybe_recv_iq_result(Config, NS, I),
I.
recv_fin(Config, I, QueryID, NS, IsComplete) when NS == ?NS_MAM_1; NS == ?NS_MAM_2 ->
recv_fin(Config, I, _QueryID, NS, IsComplete) when NS == ?NS_MAM_1; NS == ?NS_MAM_2 ->
ct:comment("Receiving fin iq for namespace '~s'", [NS]),
#iq{type = result, id = I,
sub_els = [#mam_fin{xmlns = NS,

View File

@ -142,7 +142,7 @@ unsupported_iq(Config) ->
%%%===================================================================
%%% Master-slave tests
%%%===================================================================
master_slave_cases(DB) ->
master_slave_cases(_DB) ->
{offline_master_slave, [sequence],
[master_slave_test(flex),
master_slave_test(send_all),
@ -233,8 +233,6 @@ mucsub_mam_slave(Config) ->
gen_mod:update_module(Server, mod_mam, #{user_mucsub_from_muc_archive => true}),
Room = suite:muc_room_jid(Config),
MyJID = my_jid(Config),
MyJIDBare = jid:remove_resource(MyJID),
ok = mam_tests:set_default(Config, always),
#presence{} = send_recv(Config, #presence{}),
send(Config, #presence{type = unavailable}),

View File

@ -119,7 +119,7 @@ xupdate_master(Config) ->
sub_els = [#vcard_xupdate{hash = ImgHash}]} = recv_presence(Config),
#iq{type = result, sub_els = []} =
send_recv(Config, #iq{type = set, sub_els = [#vcard_temp{}]}),
?recv2(#presence{from = MyJID, type = available,
{_, _} = ?recv2(#presence{from = MyJID, type = available,
sub_els = [#vcard_xupdate{hash = undefined}]},
#presence{from = Peer, type = unavailable}),
disconnect(Config).