=== Test case: muc_light_http_api_SUITE:delete_room_without_having_a_membership/1 (click for source code)

=== Config value:

    [{watchdog,<0.28533.1>},
     {mim_data_dir,"/home/circleci/project/big_tests/tests/muc_light_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_light_http_api_SUITE.logs/run.2022-01-25_16.31.49/muc_light_http_api_suite.delete_room_without_having_a_membership.122370.html"},
     {tc_group_properties,[{name,negative},parallel]},
     {tc_group_path,[]},
     {data_dir,"/home/circleci/project/big_tests/_build/default/lib/mongoose_tests/ebin/muc_light_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_light_http_api_SUITE.logs/run.2022-01-25_16.31.49/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:50


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

*** User 2022-01-25 16:31:50.404 ***
alicE_delete_room_without_having_a_membership_1865@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:50.405 ***
alicE_delete_room_without_having_a_membership_1865@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='9334ff1eb331e003' from='localhost' version='1.0' xml:lang='en'>

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



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



*** User 2022-01-25 16:31:50.406 ***
alicE_delete_room_without_having_a_membership_1865@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:50.407 ***
alicE_delete_room_without_having_a_membership_1865@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='53ae7f0b471e54d8' from='localhost' version='1.0' xml:lang='en'>

*** User 2022-01-25 16:31:50.407 ***
alicE_delete_room_without_having_a_membership_1865@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:50.407 ***
alicE_delete_room_without_having_a_membership_1865@localhost/res1 out
<iq type='set' id='52f143d9d119a8046fce25bb801b6775'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2022-01-25 16:31:50.407 ***
alicE_delete_room_without_having_a_membership_1865@localhost/res1 in
<iq id='52f143d9d119a8046fce25bb801b6775' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>alicE_delete_room_without_having_a_membership_1865@localhost/res1</jid>
	</bind>
</iq>



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



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



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



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



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

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



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



*** User 2022-01-25 16:31:50.411 ***
bOb_delete_room_without_having_a_membership_1865@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:50.412 ***
bOb_delete_room_without_having_a_membership_1865@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='71320680482080d8' from='localhost' version='1.0' xml:lang='en'>

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



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



*** User 2022-01-25 16:31:50.412 ***
bOb_delete_room_without_having_a_membership_1865@localhost/res1 out
<iq type='set' id='02064c0b27b5913e04323cdfc6d7deac'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-01-25 16:31:50.413 ***
bOb_delete_room_without_having_a_membership_1865@localhost/res1 in
<iq type='result' id='02064c0b27b5913e04323cdfc6d7deac'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



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



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



*** User 2022-01-25 16:31:50.419 ***
kate_delete_room_without_having_a_membership_1865@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:50.420 ***
kate_delete_room_without_having_a_membership_1865@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='41832c0ef9037daf' from='localhost' version='1.0' xml:lang='en'>

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



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



*** User 2022-01-25 16:31:50.422 ***
kate_delete_room_without_having_a_membership_1865@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:50.423 ***
kate_delete_room_without_having_a_membership_1865@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='109d4e48216ad20a' from='localhost' version='1.0' xml:lang='en'>

*** User 2022-01-25 16:31:50.423 ***
kate_delete_room_without_having_a_membership_1865@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:50.423 ***
kate_delete_room_without_having_a_membership_1865@localhost/res1 out
<iq type='set' id='9b8fc4f5cbfd89024e3fa9089ee605ee'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2022-01-25 16:31:50.423 ***
kate_delete_room_without_having_a_membership_1865@localhost/res1 in
<iq id='9b8fc4f5cbfd89024e3fa9089ee605ee' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>kate_delete_room_without_having_a_membership_1865@localhost/res1</jid>
	</bind>
</iq>



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



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



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



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



*** User 2022-01-25 16:31:50.425 ***
alicE_delete_room_without_having_a_membership_1865@localhost/res1 out
<iq type='set' id='0a6ee7d2dc2258ed347edf1cde3f40c6' to='muclight.localhost'>
	<query xmlns='urn:xmpp:muclight:0#create'>
		<configuration>
			<roomname>wonderland</roomname>
		</configuration>
		<occupants>
			<user affiliation='member'>bob_delete_room_without_having_a_membership_1865@localhost</user>
		</occupants>
	</query>
</iq>



*** User 2022-01-25 16:31:50.429 ***
alicE_delete_room_without_having_a_membership_1865@localhost/res1 in
<message from='1643-128310-425996@muclight.localhost' to='alice_delete_room_without_having_a_membership_1865@localhost' id='0a6ee7d2dc2258ed347edf1cde3f40c6' type='groupchat'>
	<x xmlns='urn:xmpp:muclight:0#affiliations'>
		<version>1643-128310-425988</version>
		<user affiliation='owner'>alice_delete_room_without_having_a_membership_1865@localhost</user>
	</x>
	<body/>
</message>



*** User 2022-01-25 16:31:50.429 ***
alicE_delete_room_without_having_a_membership_1865@localhost/res1 in
<iq from='muclight.localhost' to='alicE_delete_room_without_having_a_membership_1865@localhost/res1' id='0a6ee7d2dc2258ed347edf1cde3f40c6' type='result'/>



*** User 2022-01-25 16:31:50.429 ***
bOb_delete_room_without_having_a_membership_1865@localhost/res1 in
<message from='1643-128310-425996@muclight.localhost' to='bob_delete_room_without_having_a_membership_1865@localhost' id='0a6ee7d2dc2258ed347edf1cde3f40c6' type='groupchat'>
	<x xmlns='urn:xmpp:muclight:0#affiliations'>
		<version>1643-128310-425988</version>
		<user affiliation='member'>bob_delete_room_without_having_a_membership_1865@localhost</user>
	</x>
	<body/>
</message>



*** User 2022-01-25 16:31:50.441 ***
REST request fails:
Code: 403
Req: {<0.28600.1>,
      <<"/api/muc-lights/muclight.localhost/wonderland/kate_delete_room_without_having_a_membership_1865@localhost/management">>,
      <<"DELETE">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"01d55d94ebd45d78">>}],
      <<>>}
Result: {{<<"403">>,<<"Forbidden">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 25 Jan 2022 16:31:50 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"36">>}],
         <<"given user does not occupy this room">>,167,2155}
Params: #{body => <<>>,method => <<"DELETE">>,
          path =>
              <<"/api/muc-lights/muclight.localhost/wonderland/kate_delete_room_without_having_a_membership_1865@localhost/management">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


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

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

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

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

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

*** User 2022-01-25 16:31:50.443 ***
alicE_delete_room_without_having_a_membership_1865@localhost/res1 in
</stream:stream>
*** CT 2022-01-25 16:31:50.445 *** View log from node ejabberd2@localhost when finished ejabberd2@localhost_2339.html
*** CT 2022-01-25 16:31:50.446 *** View log from node mongooseim@localhost when finished mongooseim@localhost_5399.html



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