=== Test case: rest_SUITE:session_can_be_kicked/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.session_can_be_kicked.117891.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.043 *** View log from node mongooseim@localhost when started mongooseim@localhost_5707.html
*** CT 2022-01-25 16:34:20.043 *** View log from node ejabberd2@localhost when started ejabberd2@localhost_2377.html

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

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



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



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

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



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



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



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



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



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



*** User 2022-01-25 16:34:20.087 ***
REST request:
Code: 200
Req: {<0.7913.2>,<<"/api/sessions/localhost">>,<<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"d521fc591e8f4a5b">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:34:19 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"215">>}],
         <<"[\"alice_messages_error_handling_2209@localhost/res1\",\"alice_messages_can_be_paginated_2210@localhost/res1\",\"alice_session_can_be_kicked_2206@localhost/res1\",\"alice_stanzas_are_sent_and_received_2208@localhost/res1\"]">>,
         340,570}
Params: #{body => <<>>,method => <<"GET">>,
          path => <<"/api/sessions/localhost">>,return_headers => true,
          role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-01-25 16:34:20.089 ***
REST request:
Code: 204
Req: {<0.7922.2>,
      <<"/api/sessions/localhost/alicE_session_can_be_kicked_2206/res1">>,
      <<"DELETE">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"94df3fcc54d97509">>}],
      <<>>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:34:19 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,562}
Params: #{body => <<>>,method => <<"DELETE">>,
          path =>
              <<"/api/sessions/localhost/alicE_session_can_be_kicked_2206/res1">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-01-25 16:34:20.089 ***
alicE_session_can_be_kicked_2206@localhost/res1 in
<stream:error>
	<conflict xmlns='urn:ietf:params:xml:ns:xmpp-streams'/>
	<text xml:lang='en' xmlns='urn:ietf:params:xml:ns:xmpp-streams'>kicked</text>
</stream:error>



*** User 2022-01-25 16:34:20.130 ***
REST request:
Code: 200
Req: {<0.7925.2>,<<"/api/sessions/localhost">>,<<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"04c21d6affbd90d9">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:34:19 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"274">>}],
         <<"[\"alice_messages_error_handling_2209@localhost/res1\",\"alice_messages_can_be_paginated_2210@localhost/res1\",\"alice_messages_are_sent_and_received_2207@localhost/res1\",\"alice_messages_are_archived_2211@localhost/res1\",\"alice_stanzas_are_sent_and_received_2208@localhost/res1\"]">>,
         399,977}
Params: #{body => <<>>,method => <<"GET">>,
          path => <<"/api/sessions/localhost">>,return_headers => true,
          role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-01-25 16:34:20.132 ***
REST request fails:
Code: 404
Req: {<0.7928.2>,
      <<"/api/sessions/localhost/alicE_session_can_be_kicked_2206/res1">>,
      <<"DELETE">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"cb167a3e7dc5d864">>}],
      <<>>}
Result: {{<<"404">>,<<"Not Found">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:34:19 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"17">>}],
         <<"no active session">>,148,824}
Params: #{body => <<>>,method => <<"DELETE">>,
          path =>
              <<"/api/sessions/localhost/alicE_session_can_be_kicked_2206/res1">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}

*** CT 2022-01-25 16:34:20.135 *** View log from node ejabberd2@localhost when finished ejabberd2@localhost_2377.html
*** CT 2022-01-25 16:34:20.136 *** 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