=== Test case: muc_http_api_SUITE:message_errors/1 (click for source code)
=== Config value:
[{watchdog,<0.91353.0>},
{preset,"pgsql_mnesia"},
{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@9e4a8689b615.2024-04-16_10.12.19/big_tests.tests.muc_http_api_SUITE.logs/run.2024-04-16_10.26.55/muc_http_api_suite.message_errors.282626.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@9e4a8689b615.2024-04-16_10.12.19/big_tests.tests.muc_http_api_SUITE.logs/run.2024-04-16_10.26.55/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@9e4a8689b615.2024-04-16_10.12.19"
=== Started at 2024-04-16 10:27:00
*** User 2024-04-16 10:27:00.425 ***🔗
REST request:
Code: 201
Req: {<0.91394.0>,<<"/api/mucs/localhost">>,<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"2a82c097eabc292e">>}],
<<"{\"nick\":\"ali\",\"owner\":\"alicE_message_errors_3600@localhost\",\"name\":\"wonderland-20.414856\"}">>}
Result: {{<<"201">>,<<"Created">>},
[{<<"server">>,<<"Cowboy">>},
{<<"location">>,
<<"http://localhost:8088/api/mucs/localhost/wonderland-20.414856">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:27:00 GMT">>},
{<<"content-type">>,<<"text/html">>},
{<<"content-length">>,<<"20">>}],
<<"wonderland-20.414856">>,215,2141}
Params: #{path => <<"/api/mucs/localhost">>,
server => #{node => mongooseim@localhost},
method => <<"POST">>,
body =>
<<"{\"nick\":\"ali\",\"owner\":\"alicE_message_errors_3600@localhost\",\"name\":\"wonderland-20.414856\"}">>,
role => admin,return_headers => true}
*** User 2024-04-16 10:27:00.427 ***🔗
REST request:
Code: 204
Req: {<0.91404.0>,<<"/api/mucs/localhost/thisroomdoesnotexist/messages">>,
<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"96ebda1df6249e75">>}],
<<"{\"from\":\"alicE_message_errors_3600@localhost\",\"body\":\"Greetings!\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:27:00 GMT">>}],
<<>>,80,901}
Params: #{path => <<"/api/mucs/localhost/thisroomdoesnotexist/messages">>,
server => #{node => mongooseim@localhost},
method => <<"POST">>,
body =>
<<"{\"from\":\"alicE_message_errors_3600@localhost\",\"body\":\"Greetings!\"}">>,
role => admin,return_headers => true}
*** User 2024-04-16 10:27:00.430 ***🔗
REST request fails:
Code: 400
Req: {<0.91410.0>,<<"/api/mucs/localhost/wonderland-20.414856/messages">>,
<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"2437fb1e23fcd7f2">>}],
<<"{\"from\":\"alicE_message_errors_3600@localhost\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:27:00 GMT">>},
{<<"content-type">>,<<"text/html">>},
{<<"content-length">>,<<"22">>}],
<<"\"Missing message body\"">>,148,821}
Params: #{path => <<"/api/mucs/localhost/wonderland-20.414856/messages">>,
server => #{node => mongooseim@localhost},
method => <<"POST">>,
body => <<"{\"from\":\"alicE_message_errors_3600@localhost\"}">>,
role => admin,return_headers => true}
*** User 2024-04-16 10:27:00.432 ***🔗
REST request fails:
Code: 400
Req: {<0.91418.0>,<<"/api/mucs/localhost/wonderland-20.414856/messages">>,
<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"242dda4f5545e251">>}],
<<"{\"body\":\"Greetings!\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:27:00 GMT">>},
{<<"content-type">>,<<"text/html">>},
{<<"content-length">>,<<"20">>}],
<<"\"Missing sender JID\"">>,146,658}
Params: #{path => <<"/api/mucs/localhost/wonderland-20.414856/messages">>,
server => #{node => mongooseim@localhost},
method => <<"POST">>,body => <<"{\"body\":\"Greetings!\"}">>,
role => admin,return_headers => true}
*** User 2024-04-16 10:27:00.434 ***🔗
REST request fails:
Code: 400
Req: {<0.91425.0>,<<"/api/mucs/localhost/wonderland-20.414856/messages">>,
<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"8e8fe55a2169258a">>}],
<<"{\"from\":\"@invalid\",\"body\":\"Greetings!\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:27:00 GMT">>},
{<<"content-type">>,<<"text/html">>},
{<<"content-length">>,<<"20">>}],
<<"\"Invalid sender JID\"">>,146,717}
Params: #{path => <<"/api/mucs/localhost/wonderland-20.414856/messages">>,
server => #{node => mongooseim@localhost},
method => <<"POST">>,
body => <<"{\"from\":\"@invalid\",\"body\":\"Greetings!\"}">>,
role => admin,return_headers => true}
=== Ended at 2024-04-16 10:27:00
=== successfully completed test case
=== === Returned value: {{<<"400">>,<<"Bad Request">>},<<"Invalid sender JID">>}