=== Test case: muc_http_api_SUITE:message_errors/1 (click for source code)

=== Config value:

    [{watchdog,<0.65311.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@76d8bb481028.2024-03-11_08.55.19/big_tests.tests.muc_http_api_SUITE.logs/run.2024-03-11_09.07.22/muc_http_api_suite.message_errors.94980.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@76d8bb481028.2024-03-11_08.55.19/big_tests.tests.muc_http_api_SUITE.logs/run.2024-03-11_09.07.22/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@76d8bb481028.2024-03-11_08.55.19"

=== Started at 2024-03-11 09:07:27


*** CT 2024-03-11 09:07:27.475 *** View log from node mongooseim@localhost when started🔗 mongooseim@localhost_4290.html

*** User 2024-03-11 09:07:27.489 ***🔗
REST request:
Code: 201
Req: {<0.65348.0>,<<"/api/mucs/localhost">>,<<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"20291cd0ac328420">>}],
      <<"{\"nick\":\"ali\",\"owner\":\"alicE_message_errors_2534@localhost\",\"name\":\"wonderland-47.476611\"}">>}
Result: {{<<"201">>,<<"Created">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"location">>,
           <<"http://localhost:8088/api/mucs/localhost/wonderland-47.476611">>},
          {<<"date">>,<<"Mon, 11 Mar 2024 09:07:26 GMT">>},
          {<<"content-type">>,<<"text/html">>},
          {<<"content-length">>,<<"20">>}],
         <<"wonderland-47.476611">>,215,2664}
Params: #{path => <<"/api/mucs/localhost">>,
          server => #{node => mongooseim@localhost},
          body =>
              <<"{\"nick\":\"ali\",\"owner\":\"alicE_message_errors_2534@localhost\",\"name\":\"wonderland-47.476611\"}">>,
          method => <<"POST">>,role => admin,return_headers => true}


*** User 2024-03-11 09:07:27.491 ***🔗
REST request:
Code: 204
Req: {<0.65360.0>,<<"/api/mucs/localhost/thisroomdoesnotexist/messages">>,
      <<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"882e9832fb2fd513">>}],
      <<"{\"body\":\"Greetings!\",\"from\":\"alicE_message_errors_2534@localhost\"}">>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Mon, 11 Mar 2024 09:07:26 GMT">>}],
         <<>>,80,1054}
Params: #{path => <<"/api/mucs/localhost/thisroomdoesnotexist/messages">>,
          server => #{node => mongooseim@localhost},
          body =>
              <<"{\"body\":\"Greetings!\",\"from\":\"alicE_message_errors_2534@localhost\"}">>,
          method => <<"POST">>,role => admin,return_headers => true}


*** User 2024-03-11 09:07:27.493 ***🔗
REST request fails:
Code: 400
Req: {<0.65366.0>,<<"/api/mucs/localhost/wonderland-47.476611/messages">>,
      <<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"dd2db995210e6182">>}],
      <<"{\"from\":\"alicE_message_errors_2534@localhost\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Mon, 11 Mar 2024 09:07:26 GMT">>},
          {<<"content-type">>,<<"text/html">>},
          {<<"content-length">>,<<"22">>}],
         <<"\"Missing message body\"">>,148,741}
Params: #{path => <<"/api/mucs/localhost/wonderland-47.476611/messages">>,
          server => #{node => mongooseim@localhost},
          body => <<"{\"from\":\"alicE_message_errors_2534@localhost\"}">>,
          method => <<"POST">>,role => admin,return_headers => true}


*** User 2024-03-11 09:07:27.495 ***🔗
REST request fails:
Code: 400
Req: {<0.65374.0>,<<"/api/mucs/localhost/wonderland-47.476611/messages">>,
      <<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"9071d22701992678">>}],
      <<"{\"body\":\"Greetings!\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Mon, 11 Mar 2024 09:07:26 GMT">>},
          {<<"content-type">>,<<"text/html">>},
          {<<"content-length">>,<<"20">>}],
         <<"\"Missing sender JID\"">>,146,834}
Params: #{path => <<"/api/mucs/localhost/wonderland-47.476611/messages">>,
          server => #{node => mongooseim@localhost},
          body => <<"{\"body\":\"Greetings!\"}">>,method => <<"POST">>,
          role => admin,return_headers => true}


*** User 2024-03-11 09:07:27.496 ***🔗
REST request fails:
Code: 400
Req: {<0.65377.0>,<<"/api/mucs/localhost/wonderland-47.476611/messages">>,
      <<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"a86fe3e2eb78b60b">>}],
      <<"{\"body\":\"Greetings!\",\"from\":\"@invalid\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Mon, 11 Mar 2024 09:07:26 GMT">>},
          {<<"content-type">>,<<"text/html">>},
          {<<"content-length">>,<<"20">>}],
         <<"\"Invalid sender JID\"">>,146,710}
Params: #{path => <<"/api/mucs/localhost/wonderland-47.476611/messages">>,
          server => #{node => mongooseim@localhost},
          body => <<"{\"body\":\"Greetings!\",\"from\":\"@invalid\"}">>,
          method => <<"POST">>,role => admin,return_headers => true}

*** CT 2024-03-11 09:07:27.500 *** View log from node mongooseim@localhost when finished🔗 mongooseim@localhost_4290.html



=== Ended at 2024-03-11 09:07:27
=== successfully completed test case
=== === Returned value: {{<<"400">>,<<"Bad Request">>},<<"Invalid sender JID">>}