=== Test case: muc_http_api_SUITE:message_errors/1 (click for source code)
=== Config value:
[{watchdog,<0.68682.0>},
{preset,"pgsql_cets"},
{mim_data_dir,"/home/circleci/project/big_tests/tests/muc_http_api_SUITE_data"},
{tc_logfile,"/home/circleci/project/big_tests/ct_report/ct_run.test@81b4ed498ac1.2024-04-23_23.21.08/big_tests.tests.muc_http_api_SUITE.logs/run.2024-04-23_23.33.03/muc_http_api_suite.message_errors.178818.html"},
{tc_group_properties,[{name,negative},parallel]},
{tc_group_path,[]},
{data_dir,"/home/circleci/project/big_tests/_build/default/lib/mongoose_tests/ebin/muc_http_api_SUITE_data/"},
{priv_dir,"/home/circleci/project/big_tests/ct_report/ct_run.test@81b4ed498ac1.2024-04-23_23.21.08/big_tests.tests.muc_http_api_SUITE.logs/run.2024-04-23_23.33.03/log_private/"},
{escalus_users,[{alice,[{username,<<"alicE">>},
{server,<<"localhost">>},
{password,<<"matygrysa">>}]},
{bob,[{username,<<"bOb">>},
{server,<<"localhost">>},
{password,<<"makrolika">>}]},
{kate,[{username,<<"kate">>},
{server,<<"localhost">>},
{password,<<"makrowe;p">>}]}]}]
=== Current directory is "/home/circleci/project/big_tests/ct_report/ct_run.test@81b4ed498ac1.2024-04-23_23.21.08"
=== Started at 2024-04-23 23:33:09
*** User 2024-04-23 23:33:09.311 ***🔗
REST request:
Code: 201
Req: {<0.68723.0>,<<"/api/mucs/localhost">>,<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"50b7854d05272f8b">>}],
<<"{\"nick\":\"ali\",\"owner\":\"alicE_message_errors_2596@localhost\",\"name\":\"wonderland-89.304283\"}">>}
Result: {{<<"201">>,<<"Created">>},
[{<<"server">>,<<"Cowboy">>},
{<<"location">>,
<<"http://localhost:8088/api/mucs/localhost/wonderland-89.304283">>},
{<<"date">>,<<"Tue, 23 Apr 2024 23:33:09 GMT">>},
{<<"content-type">>,<<"text/html">>},
{<<"content-length">>,<<"20">>}],
<<"wonderland-89.304283">>,215,2086}
Params: #{path => <<"/api/mucs/localhost">>,
server => #{node => mongooseim@localhost},
body =>
<<"{\"nick\":\"ali\",\"owner\":\"alicE_message_errors_2596@localhost\",\"name\":\"wonderland-89.304283\"}">>,
role => admin,method => <<"POST">>,return_headers => true}
*** User 2024-04-23 23:33:09.313 ***🔗
REST request:
Code: 204
Req: {<0.68733.0>,<<"/api/mucs/localhost/thisroomdoesnotexist/messages">>,
<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"d590cfaa1bc3c2ff">>}],
<<"{\"from\":\"alicE_message_errors_2596@localhost\",\"body\":\"Greetings!\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 23 Apr 2024 23:33:09 GMT">>}],
<<>>,80,1169}
Params: #{path => <<"/api/mucs/localhost/thisroomdoesnotexist/messages">>,
server => #{node => mongooseim@localhost},
body =>
<<"{\"from\":\"alicE_message_errors_2596@localhost\",\"body\":\"Greetings!\"}">>,
role => admin,method => <<"POST">>,return_headers => true}
*** User 2024-04-23 23:33:09.315 ***🔗
REST request fails:
Code: 400
Req: {<0.68741.0>,<<"/api/mucs/localhost/wonderland-89.304283/messages">>,
<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"8375be04dc6301b4">>}],
<<"{\"from\":\"alicE_message_errors_2596@localhost\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 23 Apr 2024 23:33:09 GMT">>},
{<<"content-type">>,<<"text/html">>},
{<<"content-length">>,<<"22">>}],
<<"\"Missing message body\"">>,148,423}
Params: #{path => <<"/api/mucs/localhost/wonderland-89.304283/messages">>,
server => #{node => mongooseim@localhost},
body => <<"{\"from\":\"alicE_message_errors_2596@localhost\"}">>,
role => admin,method => <<"POST">>,return_headers => true}
*** User 2024-04-23 23:33:09.319 ***🔗
REST request fails:
Code: 400
Req: {<0.68748.0>,<<"/api/mucs/localhost/wonderland-89.304283/messages">>,
<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"46f5b87c5c7917eb">>}],
<<"{\"body\":\"Greetings!\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 23 Apr 2024 23:33:09 GMT">>},
{<<"content-type">>,<<"text/html">>},
{<<"content-length">>,<<"20">>}],
<<"\"Missing sender JID\"">>,146,707}
Params: #{path => <<"/api/mucs/localhost/wonderland-89.304283/messages">>,
server => #{node => mongooseim@localhost},
body => <<"{\"body\":\"Greetings!\"}">>,role => admin,
method => <<"POST">>,return_headers => true}
*** User 2024-04-23 23:33:09.321 ***🔗
REST request fails:
Code: 400
Req: {<0.68754.0>,<<"/api/mucs/localhost/wonderland-89.304283/messages">>,
<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"0828353337bcef92">>}],
<<"{\"from\":\"@invalid\",\"body\":\"Greetings!\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 23 Apr 2024 23:33:09 GMT">>},
{<<"content-type">>,<<"text/html">>},
{<<"content-length">>,<<"20">>}],
<<"\"Invalid sender JID\"">>,146,529}
Params: #{path => <<"/api/mucs/localhost/wonderland-89.304283/messages">>,
server => #{node => mongooseim@localhost},
body => <<"{\"from\":\"@invalid\",\"body\":\"Greetings!\"}">>,
role => admin,method => <<"POST">>,return_headers => true}
=== Ended at 2024-04-23 23:33:09
=== successfully completed test case
=== === Returned value: {{<<"400">>,<<"Bad Request">>},<<"Invalid sender JID">>}