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

=== Config value:

    [{watchdog,<0.27133.1>},
     {mim_data_dir,"/home/circleci/project/big_tests/tests/muc_http_api_SUITE_data"},
     {preset,"odbc_mssql_mnesia"},
     {tc_logfile,"/home/circleci/project/big_tests/ct_report/ct_run.test@ebe8a8f9fc53.2022-01-25_16.21.59/big_tests.tests.muc_http_api_SUITE.logs/run.2022-01-25_16.31.33/muc_http_api_suite.failed_messages.64516.html"},
     {tc_group_properties,[{name,negative},{repeat_until_all_ok,3},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@ebe8a8f9fc53.2022-01-25_16.21.59/big_tests.tests.muc_http_api_SUITE.logs/run.2022-01-25_16.31.33/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@ebe8a8f9fc53.2022-01-25_16.21.59"

=== Started at 2022-01-25 16:31:38


*** CT 2022-01-25 16:31:38.990 *** View log from node mongooseim@localhost when started mongooseim@localhost_5386.html
*** CT 2022-01-25 16:31:38.990 *** View log from node ejabberd2@localhost when started ejabberd2@localhost_2339.html

*** User 2022-01-25 16:31:38.997 ***
alicE_failed_messages_1855@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2022-01-25 16:31:38.998 ***
alicE_failed_messages_1855@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='5f4f935191ac810f' from='localhost' version='1.0' xml:lang='en'>

*** User 2022-01-25 16:31:38.998 ***
alicE_failed_messages_1855@localhost/res1 in
<stream:features>
	<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>
	<compression xmlns='http://jabber.org/features/compress'>
		<method>zlib</method>
	</compression>
	<mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
		<mechanism>SCRAM-SHA-256</mechanism>
		<mechanism>PLAIN</mechanism>
	</mechanisms>
	<register xmlns='http://jabber.org/features/iq-register'/>
	<amp xmlns='http://jabber.org/feature/amp'/>
	<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>



*** User 2022-01-25 16:31:38.998 ***
alicE_failed_messages_1855@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGFsaWNFX2ZhaWxlZF9tZXNzYWdlc18xODU1AG1hdHlncnlzYQ==</auth>



*** User 2022-01-25 16:31:38.999 ***
alicE_failed_messages_1855@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>



*** User 2022-01-25 16:31:38.999 ***
alicE_failed_messages_1855@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2022-01-25 16:31:38.999 ***
alicE_failed_messages_1855@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='cf026da721a7b666' from='localhost' version='1.0' xml:lang='en'>

*** User 2022-01-25 16:31:38.999 ***
alicE_failed_messages_1855@localhost/res1 in
<stream:features>
	<compression xmlns='http://jabber.org/features/compress'>
		<method>zlib</method>
	</compression>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'/>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
	<register xmlns='http://jabber.org/features/iq-register'/>
	<amp xmlns='http://jabber.org/feature/amp'/>
	<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>



*** User 2022-01-25 16:31:38.999 ***
alicE_failed_messages_1855@localhost/res1 out
<iq type='set' id='18fc662104099ad73727800514185a86'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2022-01-25 16:31:39.000 ***
alicE_failed_messages_1855@localhost/res1 in
<iq id='18fc662104099ad73727800514185a86' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>alicE_failed_messages_1855@localhost/res1</jid>
	</bind>
</iq>



*** User 2022-01-25 16:31:39.000 ***
alicE_failed_messages_1855@localhost/res1 out
<iq type='set' id='58e2e0354052dc320d11d5867f350bae'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-01-25 16:31:39.000 ***
alicE_failed_messages_1855@localhost/res1 in
<iq type='result' id='58e2e0354052dc320d11d5867f350bae'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-01-25 16:31:39.000 ***
alicE_failed_messages_1855@localhost/res1 out
<presence/>



*** User 2022-01-25 16:31:39.001 ***
alicE_failed_messages_1855@localhost/res1 in
<presence from='alicE_failed_messages_1855@localhost/res1' to='alice_failed_messages_1855@localhost/res1' xml:lang='en'/>



*** User 2022-01-25 16:31:39.002 ***
bOb_failed_messages_1855@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2022-01-25 16:31:39.002 ***
bOb_failed_messages_1855@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='5f43c5bd1e19634e' from='localhost' version='1.0' xml:lang='en'>

*** User 2022-01-25 16:31:39.002 ***
bOb_failed_messages_1855@localhost/res1 in
<stream:features>
	<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>
	<compression xmlns='http://jabber.org/features/compress'>
		<method>zlib</method>
	</compression>
	<mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
		<mechanism>SCRAM-SHA-256</mechanism>
		<mechanism>PLAIN</mechanism>
	</mechanisms>
	<register xmlns='http://jabber.org/features/iq-register'/>
	<amp xmlns='http://jabber.org/feature/amp'/>
	<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>



*** User 2022-01-25 16:31:39.002 ***
bOb_failed_messages_1855@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGJPYl9mYWlsZWRfbWVzc2FnZXNfMTg1NQBtYWtyb2xpa2E=</auth>



*** User 2022-01-25 16:31:39.004 ***
bOb_failed_messages_1855@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>



*** User 2022-01-25 16:31:39.004 ***
bOb_failed_messages_1855@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2022-01-25 16:31:39.004 ***
bOb_failed_messages_1855@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='42cb1eb23cbce703' from='localhost' version='1.0' xml:lang='en'>

*** User 2022-01-25 16:31:39.004 ***
bOb_failed_messages_1855@localhost/res1 in
<stream:features>
	<compression xmlns='http://jabber.org/features/compress'>
		<method>zlib</method>
	</compression>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'/>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
	<register xmlns='http://jabber.org/features/iq-register'/>
	<amp xmlns='http://jabber.org/feature/amp'/>
	<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>



*** User 2022-01-25 16:31:39.004 ***
bOb_failed_messages_1855@localhost/res1 out
<iq type='set' id='9411f13a4afdeaf3420b4f8a2b3b3817'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2022-01-25 16:31:39.005 ***
bOb_failed_messages_1855@localhost/res1 in
<iq id='9411f13a4afdeaf3420b4f8a2b3b3817' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>bOb_failed_messages_1855@localhost/res1</jid>
	</bind>
</iq>



*** User 2022-01-25 16:31:39.005 ***
bOb_failed_messages_1855@localhost/res1 out
<iq type='set' id='529aaa888f15bbe26fb9d53449cd5924'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-01-25 16:31:39.005 ***
bOb_failed_messages_1855@localhost/res1 in
<iq type='result' id='529aaa888f15bbe26fb9d53449cd5924'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-01-25 16:31:39.005 ***
bOb_failed_messages_1855@localhost/res1 out
<presence/>



*** User 2022-01-25 16:31:39.006 ***
bOb_failed_messages_1855@localhost/res1 in
<presence from='bOb_failed_messages_1855@localhost/res1' to='bob_failed_messages_1855@localhost/res1' xml:lang='en'/>



*** User 2022-01-25 16:31:39.010 ***
REST request:
Code: 201
Req: {<0.27162.1>,<<"/api/mucs/localhost">>,<<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"f29d763bade55bdb">>}],
      <<"{\"owner\":\"alicE_failed_messages_1855@localhost\",\"nick\":\"ali\",\"name\":\"wonderland-98.990934\"}">>}
Result: {{<<"201">>,<<"Created">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"location">>,
           <<"http://localhost:8088/api/mucs/localhost/wonderland-98.990934">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:31:38 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"20">>}],
         <<"wonderland-98.990934">>,222,2110}
Params: #{body =>
              <<"{\"owner\":\"alicE_failed_messages_1855@localhost\",\"nick\":\"ali\",\"name\":\"wonderland-98.990934\"}">>,
          method => <<"POST">>,path => <<"/api/mucs/localhost">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-01-25 16:31:39.011 ***
REST request fails:
Code: 404
Req: {<0.27166.1>,<<"/api/mucs/localhost/thisroomdoesnotexist/participants">>,
      <<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"4361d3322f795a7d">>}],
      <<"{\"sender\":\"alicE_failed_messages_1855@localhost\",\"recipient\":\"bOb_failed_messages_1855@localhost\",\"reason\":\"I think you'll like this room!\"}">>}
Result: {{<<"404">>,<<"Not Found">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:31:38 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"19">>}],
         <<"room does not exist">>,150,715}
Params: #{body =>
              <<"{\"sender\":\"alicE_failed_messages_1855@localhost\",\"recipient\":\"bOb_failed_messages_1855@localhost\",\"reason\":\"I think you'll like this room!\"}">>,
          method => <<"POST">>,
          path => <<"/api/mucs/localhost/thisroomdoesnotexist/participants">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-01-25 16:31:39.013 ***
REST request fails:
Code: 400
Req: {<0.27168.1>,<<"/api/mucs/localhost/wonderland-98.990934/participants">>,
      <<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"2eb48cc3348ee1ef">>}],
      <<"{\"sender\":\"alicE_failed_messages_1855@localhost\",\"recipient\":\"@badjid\",\"reason\":\"I think you'll like this room!\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:31:38 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"26">>}],
         <<"Invalid jid: <<\"@badjid\">>">>,159,687}
Params: #{body =>
              <<"{\"sender\":\"alicE_failed_messages_1855@localhost\",\"recipient\":\"@badjid\",\"reason\":\"I think you'll like this room!\"}">>,
          method => <<"POST">>,
          path => <<"/api/mucs/localhost/wonderland-98.990934/participants">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-01-25 16:31:39.015 ***
REST request fails:
Code: 400
Req: {<0.27172.1>,<<"/api/mucs/localhost/wonderland-98.990934/participants">>,
      <<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"827b415fab17fd06">>}],
      <<"{\"sender\":\"@badjid\",\"recipient\":\"bOb_failed_messages_1855@localhost\",\"reason\":\"I think you'll like this room!\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:31:38 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"26">>}],
         <<"Invalid jid: <<\"@badjid\">>">>,159,857}
Params: #{body =>
              <<"{\"sender\":\"@badjid\",\"recipient\":\"bOb_failed_messages_1855@localhost\",\"reason\":\"I think you'll like this room!\"}">>,
          method => <<"POST">>,
          path => <<"/api/mucs/localhost/wonderland-98.990934/participants">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-01-25 16:31:39.016 ***
bOb_failed_messages_1855@localhost/res1 out
</stream:stream>

*** User 2022-01-25 16:31:39.016 ***
bOb_failed_messages_1855@localhost/res1 in
</stream:stream>

*** User 2022-01-25 16:31:39.016 ***
alicE_failed_messages_1855@localhost/res1 out
</stream:stream>

*** User 2022-01-25 16:31:39.017 ***
alicE_failed_messages_1855@localhost/res1 in
</stream:stream>
*** CT 2022-01-25 16:31:39.019 *** View log from node ejabberd2@localhost when finished ejabberd2@localhost_2339.html
*** CT 2022-01-25 16:31:39.020 *** View log from node mongooseim@localhost when finished mongooseim@localhost_5386.html



=== Ended at 2022-01-25 16:31:39
=== successfully completed test case
=== === Returned value: ok