=== Test case: rest_SUITE:messages_are_sent_and_received/1 (click for source code)

=== Config value:

    [{watchdog,<0.7719.2>},
     {{ejabberd_cwd,mongooseim@localhost},
      "/home/circleci/project/_build/mim1/rel/mongooseim"},
     {mam_backend,rdbms},
     {mim_data_dir,"/home/circleci/project/big_tests/tests/rest_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.rest_SUITE.logs/run.2022-01-25_16.34.19/rest_suite.messages_are_sent_and_received.118019.html"},
     {tc_group_properties,[{name,admin},parallel]},
     {tc_group_path,[]},
     {data_dir,"/home/circleci/project/big_tests/_build/default/lib/mongoose_tests/ebin/rest_SUITE_data/"},
     {priv_dir,"/home/circleci/project/big_tests/ct_report/ct_run.test@ebe8a8f9fc53.2022-01-25_16.21.59/big_tests.tests.rest_SUITE.logs/run.2022-01-25_16.34.19/log_private/"},
     {escalus_users,[{alice,[{username,<<"alicE">>},
                             {server,<<"localhost">>},
                             {password,<<"matygrysa">>}]},
                     {bob,[{username,<<"bOb">>},
                           {server,<<"localhost">>},
                           {password,<<"makrolika">>}]}]}]

=== 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:34:20


*** CT 2022-01-25 16:34:20.045 *** View log from node mongooseim@localhost when started mongooseim@localhost_5707.html
*** CT 2022-01-25 16:34:20.045 *** View log from node ejabberd2@localhost when started ejabberd2@localhost_2377.html

*** User 2022-01-25 16:34:20.074 ***
alicE_messages_are_sent_and_received_2207@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:34:20.076 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='fa4e21e090011927' from='localhost' version='1.0' xml:lang='en'>

*** User 2022-01-25 16:34:20.076 ***
alicE_messages_are_sent_and_received_2207@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:34:20.076 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGFsaWNFX21lc3NhZ2VzX2FyZV9zZW50X2FuZF9yZWNlaXZlZF8yMjA3AG1hdHlncnlzYQ==</auth>



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



*** User 2022-01-25 16:34:20.085 ***
alicE_messages_are_sent_and_received_2207@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:34:20.085 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='8c937405843828ac' from='localhost' version='1.0' xml:lang='en'>

*** User 2022-01-25 16:34:20.086 ***
alicE_messages_are_sent_and_received_2207@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:34:20.086 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 out
<iq type='set' id='b71c0ebb1753e7c2b2a31f28df208eba'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2022-01-25 16:34:20.087 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 in
<iq id='b71c0ebb1753e7c2b2a31f28df208eba' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>alicE_messages_are_sent_and_received_2207@localhost/res1</jid>
	</bind>
</iq>



*** User 2022-01-25 16:34:20.087 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 out
<iq type='set' id='459950784bf8b48ad5b8cc6af1683302'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-01-25 16:34:20.087 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 in
<iq type='result' id='459950784bf8b48ad5b8cc6af1683302'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-01-25 16:34:20.088 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 out
<presence/>



*** User 2022-01-25 16:34:20.130 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 in
<presence from='alicE_messages_are_sent_and_received_2207@localhost/res1' to='alice_messages_are_sent_and_received_2207@localhost/res1' xml:lang='en'/>



*** User 2022-01-25 16:34:20.131 ***
bOb_messages_are_sent_and_received_2207@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:34:20.131 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='75b20f33d3ebfe0d' from='localhost' version='1.0' xml:lang='en'>

*** User 2022-01-25 16:34:20.132 ***
bOb_messages_are_sent_and_received_2207@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:34:20.132 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGJPYl9tZXNzYWdlc19hcmVfc2VudF9hbmRfcmVjZWl2ZWRfMjIwNwBtYWtyb2xpa2E=</auth>



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



*** User 2022-01-25 16:34:20.133 ***
bOb_messages_are_sent_and_received_2207@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:34:20.134 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='8bf9b4493cb069c4' from='localhost' version='1.0' xml:lang='en'>

*** User 2022-01-25 16:34:20.134 ***
bOb_messages_are_sent_and_received_2207@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:34:20.134 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 out
<iq type='set' id='5b75f71422db32923ed6564663e2dce6'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2022-01-25 16:34:20.134 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 in
<iq id='5b75f71422db32923ed6564663e2dce6' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>bOb_messages_are_sent_and_received_2207@localhost/res1</jid>
	</bind>
</iq>



*** User 2022-01-25 16:34:20.135 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 out
<iq type='set' id='5517dcece6bb0e20f01f440557e00264'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-01-25 16:34:20.135 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 in
<iq type='result' id='5517dcece6bb0e20f01f440557e00264'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-01-25 16:34:20.135 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 out
<presence/>



*** User 2022-01-25 16:34:20.139 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 in
<presence from='bOb_messages_are_sent_and_received_2207@localhost/res1' to='bob_messages_are_sent_and_received_2207@localhost/res1' xml:lang='en'/>



*** User 2022-01-25 16:34:20.162 ***
REST request:
Code: 204
Req: {<0.7951.2>,<<"/api/messages">>,<<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"474efdad857b7f70">>}],
      <<"{\"to\":\"alice_messages_are_sent_and_received_2207@localhost\",\"caller\":\"bob_messages_are_sent_and_received_2207@localhost\",\"body\":\"hello from Bob\"}">>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:34:19 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,22123}
Params: #{body =>
              <<"{\"to\":\"alice_messages_are_sent_and_received_2207@localhost\",\"caller\":\"bob_messages_are_sent_and_received_2207@localhost\",\"body\":\"hello from Bob\"}">>,
          method => <<"POST">>,path => <<"/api/messages">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-01-25 16:34:20.229 ***
REST request:
Code: 204
Req: {<0.7997.2>,<<"/api/messages">>,<<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"9d270d4f577fe920">>}],
      <<"{\"to\":\"bob_messages_are_sent_and_received_2207@localhost\",\"caller\":\"alice_messages_are_sent_and_received_2207@localhost\",\"body\":\"hello from Alice\"}">>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:34:19 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,66034}
Params: #{body =>
              <<"{\"to\":\"bob_messages_are_sent_and_received_2207@localhost\",\"caller\":\"alice_messages_are_sent_and_received_2207@localhost\",\"body\":\"hello from Alice\"}">>,
          method => <<"POST">>,path => <<"/api/messages">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-01-25 16:34:20.229 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 in
<message from='bob_messages_are_sent_and_received_2207@localhost' to='alice_messages_are_sent_and_received_2207@localhost' type='chat' id='a467d4797e710b8d'>
	<body>hello from Bob</body>
	<stanza-id by='alice_messages_are_sent_and_received_2207@localhost' id='BLJAL0NUDK81' xmlns='urn:xmpp:sid:0'/>
</message>



*** User 2022-01-25 16:34:20.229 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 in
<message from='alice_messages_are_sent_and_received_2207@localhost' to='bob_messages_are_sent_and_received_2207@localhost' type='chat' id='52a39357e34e871a'>
	<body>hello from Alice</body>
	<stanza-id by='bob_messages_are_sent_and_received_2207@localhost' id='BLJAL0O3MFO1' xmlns='urn:xmpp:sid:0'/>
</message>



*** User 2022-01-25 16:34:20.229 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 out
</stream:stream>

*** User 2022-01-25 16:34:20.230 ***
bOb_messages_are_sent_and_received_2207@localhost/res1 in
</stream:stream>

*** User 2022-01-25 16:34:20.230 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 out
</stream:stream>

*** User 2022-01-25 16:34:20.230 ***
alicE_messages_are_sent_and_received_2207@localhost/res1 in
</stream:stream>
*** CT 2022-01-25 16:34:20.232 *** View log from node ejabberd2@localhost when finished ejabberd2@localhost_2377.html
*** CT 2022-01-25 16:34:20.233 *** View log from node mongooseim@localhost when finished mongooseim@localhost_5708.html



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