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

=== Config value:

    [{watchdog,<0.26047.1>},
     {{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,"pgsql_mnesia"},
     {tc_logfile,"/home/circleci/project/big_tests/ct_report/ct_run.test@7a520fcf4274.2022-02-02_15.07.36/big_tests.tests.rest_SUITE.logs/run.2022-02-02_15.14.56/rest_suite.befriend_and_alienate.37509.html"},
     {tc_group_properties,[{name,roster},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@7a520fcf4274.2022-02-02_15.07.36/big_tests.tests.rest_SUITE.logs/run.2022-02-02_15.14.56/log_private/"},
     {escalus_users,[{alice,[{username,<<"alicE">>},
                             {server,<<"domain.example.com">>},
                             {host,<<"localhost">>},
                             {password,<<"matygrysa">>}]},
                     {bob,[{username,<<"bOb">>},
                           {server,<<"domain.example.com">>},
                           {host,<<"localhost">>},
                           {password,<<"makrolika">>}]}]}]

=== Current directory is "/home/circleci/project/big_tests/ct_report/ct_run.test@7a520fcf4274.2022-02-02_15.07.36"

=== Started at 2022-02-02 15:14:57


*** CT 2022-02-02 15:14:57.686 *** View log from node mongooseim@localhost when started mongooseim@localhost_2425.html
*** CT 2022-02-02 15:14:57.686 *** View log from node ejabberd2@localhost when started ejabberd2@localhost_628.html

*** User 2022-02-02 15:14:57.693 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 out
<stream:stream to='domain.example.com' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2022-02-02 15:14:57.693 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='f7b1177266a8cdae' from='domain.example.com' version='1.0' xml:lang='en'>

*** User 2022-02-02 15:14:57.693 ***
alicE_befriend_and_alienate_1608@domain.example.com/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-02-02 15:14:57.693 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGFsaWNFX2JlZnJpZW5kX2FuZF9hbGllbmF0ZV8xNjA4AG1hdHlncnlzYQ==</auth>



*** User 2022-02-02 15:14:57.694 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>



*** User 2022-02-02 15:14:57.694 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 out
<stream:stream to='domain.example.com' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2022-02-02 15:14:57.694 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='9846f37b1e32db38' from='domain.example.com' version='1.0' xml:lang='en'>

*** User 2022-02-02 15:14:57.694 ***
alicE_befriend_and_alienate_1608@domain.example.com/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-02-02 15:14:57.694 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 out
<iq type='set' id='64be062ed2b3a8b8c0672877afa650e7'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2022-02-02 15:14:57.694 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<iq id='64be062ed2b3a8b8c0672877afa650e7' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>alicE_befriend_and_alienate_1608@domain.example.com/res1</jid>
	</bind>
</iq>



*** User 2022-02-02 15:14:57.695 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 out
<iq type='set' id='a1024802e97cca8328d89d10bbf01361'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-02-02 15:14:57.695 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<iq type='result' id='a1024802e97cca8328d89d10bbf01361'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-02-02 15:14:57.695 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 out
<presence/>



*** User 2022-02-02 15:14:57.696 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='alicE_befriend_and_alienate_1608@domain.example.com/res1' to='alice_befriend_and_alienate_1608@domain.example.com/res1' xml:lang='en'/>



*** User 2022-02-02 15:14:57.697 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 out
<stream:stream to='domain.example.com' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2022-02-02 15:14:57.697 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='bcb7ada8c7ca7779' from='domain.example.com' version='1.0' xml:lang='en'>

*** User 2022-02-02 15:14:57.697 ***
bOb_befriend_and_alienate_1608@domain.example.com/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-02-02 15:14:57.698 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGJPYl9iZWZyaWVuZF9hbmRfYWxpZW5hdGVfMTYwOABtYWtyb2xpa2E=</auth>



*** User 2022-02-02 15:14:57.698 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>



*** User 2022-02-02 15:14:57.698 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 out
<stream:stream to='domain.example.com' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2022-02-02 15:14:57.698 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='be12a2d3a57b7536' from='domain.example.com' version='1.0' xml:lang='en'>

*** User 2022-02-02 15:14:57.699 ***
bOb_befriend_and_alienate_1608@domain.example.com/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-02-02 15:14:57.699 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 out
<iq type='set' id='da299eb71260c2b4f11736e4e2f3ea37'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2022-02-02 15:14:57.699 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<iq id='da299eb71260c2b4f11736e4e2f3ea37' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>bOb_befriend_and_alienate_1608@domain.example.com/res1</jid>
	</bind>
</iq>



*** User 2022-02-02 15:14:57.699 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 out
<iq type='set' id='ca8c2a3b80a22b190a93476590270959'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-02-02 15:14:57.699 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<iq type='result' id='ca8c2a3b80a22b190a93476590270959'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2022-02-02 15:14:57.699 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 out
<presence/>



*** User 2022-02-02 15:14:57.701 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='bOb_befriend_and_alienate_1608@domain.example.com/res1' to='bob_befriend_and_alienate_1608@domain.example.com/res1' xml:lang='en'/>



*** User 2022-02-02 15:14:57.704 ***
REST request:
Code: 200
Req: {<0.26106.1>,
      <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"9e6fc7e66f1b83a2">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"2">>}],
         <<"[]">>,125,2221}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.706 ***
REST request:
Code: 200
Req: {<0.26116.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"8804461eebc710ee">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"2">>}],
         <<"[]">>,125,1061}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.709 ***
REST request:
Code: 204
Req: {<0.26122.1>,
      <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
      <<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"14a1068a7265acee">>}],
      <<"{\"jid\":\"bob_befriend_and_alienate_1608@domain.example.com\"}">>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,1614}
Params: #{body =>
              <<"{\"jid\":\"bob_befriend_and_alienate_1608@domain.example.com\"}">>,
          method => <<"POST">>,
          path =>
              <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.711 ***
REST request:
Code: 204
Req: {<0.26129.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"d60ec057537682c7">>}],
      <<"{\"jid\":\"alice_befriend_and_alienate_1608@domain.example.com\"}">>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,1875}
Params: #{body =>
              <<"{\"jid\":\"alice_befriend_and_alienate_1608@domain.example.com\"}">>,
          method => <<"POST">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.714 ***
REST request:
Code: 200
Req: {<0.26138.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"a0da68ac2d04f96b">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"98">>}],
         <<"[{\"subscription\":\"none\",\"jid\":\"alice_befriend_and_alienate_1608@domain.example.com\",\"ask\":\"none\"}]">>,
         222,1771}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.717 ***
REST request:
Code: 200
Req: {<0.26144.1>,
      <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"879cb63dc73aebba">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"96">>}],
         <<"[{\"subscription\":\"none\",\"jid\":\"bob_befriend_and_alienate_1608@domain.example.com\",\"ask\":\"none\"}]">>,
         220,2343}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.721 ***
REST request:
Code: 204
Req: {<0.26150.1>,
      <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"112d8fe3eff2497d">>}],
      <<"{\"action\":\"subscribe\"}">>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,3448}
Params: #{body => <<"{\"action\":\"subscribe\"}">>,method => <<"PUT">>,
          path =>
              <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.724 ***
REST request:
Code: 200
Req: {<0.26155.1>,
      <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"c8b160fffd2cf0c5">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"95">>}],
         <<"[{\"subscription\":\"none\",\"jid\":\"bob_befriend_and_alienate_1608@domain.example.com\",\"ask\":\"out\"}]">>,
         219,1356}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.728 ***
REST request:
Code: 204
Req: {<0.26162.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com/alice_befriend_and_alienate_1608@domain.example.com">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"62e96082ffd5659e">>}],
      <<"{\"action\":\"subscribed\"}">>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,3262}
Params: #{body => <<"{\"action\":\"subscribed\"}">>,method => <<"PUT">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com/alice_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.730 ***
REST request:
Code: 200
Req: {<0.26168.1>,
      <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"d84e357f282b1806">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"94">>}],
         <<"[{\"subscription\":\"to\",\"jid\":\"bob_befriend_and_alienate_1608@domain.example.com\",\"ask\":\"none\"}]">>,
         218,1571}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.732 ***
REST request:
Code: 200
Req: {<0.26172.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"8b0192d6cafa92c5">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"98">>}],
         <<"[{\"subscription\":\"from\",\"jid\":\"alice_befriend_and_alienate_1608@domain.example.com\",\"ask\":\"none\"}]">>,
         222,884}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.736 ***
REST request:
Code: 204
Req: {<0.26174.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com/alice_befriend_and_alienate_1608@domain.example.com">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"d51c6259fc29278c">>}],
      <<"{\"action\":\"subscribe\"}">>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,3796}
Params: #{body => <<"{\"action\":\"subscribe\"}">>,method => <<"PUT">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com/alice_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.738 ***
REST request:
Code: 200
Req: {<0.26178.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"13b77415691d3d8e">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"97">>}],
         <<"[{\"subscription\":\"from\",\"jid\":\"alice_befriend_and_alienate_1608@domain.example.com\",\"ask\":\"out\"}]">>,
         221,828}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.741 ***
REST request:
Code: 204
Req: {<0.26182.1>,
      <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"23620dd84aa86e5f">>}],
      <<"{\"action\":\"subscribed\"}">>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,2560}
Params: #{body => <<"{\"action\":\"subscribed\"}">>,method => <<"PUT">>,
          path =>
              <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.761 ***
REST request:
Code: 200
Req: {<0.26184.1>,
      <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"8be102c4141bc5ac">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"96">>}],
         <<"[{\"subscription\":\"both\",\"jid\":\"bob_befriend_and_alienate_1608@domain.example.com\",\"ask\":\"none\"}]">>,
         220,19053}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.763 ***
REST request:
Code: 200
Req: {<0.26186.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"9be2c1f2eb3e1d18">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"98">>}],
         <<"[{\"subscription\":\"both\",\"jid\":\"alice_befriend_and_alienate_1608@domain.example.com\",\"ask\":\"none\"}]">>,
         222,885}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.769 ***
REST request:
Code: 204
Req: {<0.26188.1>,
      <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"DELETE">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"097819ad53b641ce">>}],
      <<>>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,4798}
Params: #{body => <<>>,method => <<"DELETE">>,
          path =>
              <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.770 ***
REST request:
Code: 200
Req: {<0.26190.1>,
      <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"de9c768cafd82241">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"2">>}],
         <<"[]">>,125,857}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/alice_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.772 ***
REST request:
Code: 200
Req: {<0.26192.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"c9c0b5e474c72106">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"98">>}],
         <<"[{\"subscription\":\"none\",\"jid\":\"alice_befriend_and_alienate_1608@domain.example.com\",\"ask\":\"none\"}]">>,
         222,774}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.774 ***
REST request:
Code: 204
Req: {<0.26194.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com/alice_befriend_and_alienate_1608@domain.example.com">>,
      <<"DELETE">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"eb3896252d91fc0b">>}],
      <<>>}
Result: {{<<"204">>,<<"No Content">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>}],
         <<>>,112,1286}
Params: #{body => <<>>,method => <<"DELETE">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com/alice_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.775 ***
REST request:
Code: 200
Req: {<0.26196.1>,
      <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
      <<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"ab817f7d832e61f8">>}],
      <<>>}
Result: {{<<"200">>,<<"OK">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 02 Feb 2022 15:14:57 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"2">>}],
         <<"[]">>,125,751}
Params: #{body => <<>>,method => <<"GET">>,
          path =>
              <<"/api/contacts/bob_befriend_and_alienate_1608@domain.example.com">>,
          return_headers => true,role => admin,
          server => #{node => mongooseim@localhost}}


*** User 2022-02-02 15:14:57.775 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='alice_befriend_and_alienate_1608@domain.example.com' to='alice_befriend_and_alienate_1608@domain.example.com/res1' id='pusheda5f13b1f76432e' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='none' jid='bob_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:14:57.775 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='alice_befriend_and_alienate_1608@domain.example.com' to='alice_befriend_and_alienate_1608@domain.example.com/res1' id='pushe1ff98ef5ec0f22d' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item ask='subscribe' subscription='none' jid='bob_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:14:57.775 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='bOb_befriend_and_alienate_1608@domain.example.com/res1' to='alice_befriend_and_alienate_1608@domain.example.com/res1' xml:lang='en'/>



*** User 2022-02-02 15:14:57.776 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='alice_befriend_and_alienate_1608@domain.example.com' to='alice_befriend_and_alienate_1608@domain.example.com/res1' id='pushe60489738a283fbd' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='to' jid='bob_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:14:57.776 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='bob_befriend_and_alienate_1608@domain.example.com' to='alice_befriend_and_alienate_1608@domain.example.com/res1' type='subscribed'/>



*** User 2022-02-02 15:14:57.776 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='alice_befriend_and_alienate_1608@domain.example.com' to='alice_befriend_and_alienate_1608@domain.example.com/res1' id='push8c74ff1e9510d900' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='to' jid='bob_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:14:57.776 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='bob_befriend_and_alienate_1608@domain.example.com' to='alice_befriend_and_alienate_1608@domain.example.com/res1' type='subscribe'/>



*** User 2022-02-02 15:14:57.776 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='alice_befriend_and_alienate_1608@domain.example.com' to='alice_befriend_and_alienate_1608@domain.example.com/res1' id='pushc3b1d7402d765d9a' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='both' jid='bob_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:14:57.776 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='alice_befriend_and_alienate_1608@domain.example.com' to='alice_befriend_and_alienate_1608@domain.example.com/res1' id='pushdce297b25b2a543b' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='remove' jid='bob_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:14:57.776 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='bOb_befriend_and_alienate_1608@domain.example.com/res1' to='alice_befriend_and_alienate_1608@domain.example.com/res1' type='unavailable'/>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='bob_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' id='push2acb0f8d8cd92ec6' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='none' jid='alice_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='alice_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' type='subscribe'/>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='bob_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' id='pushca79acbfb8daebe1' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='from' jid='alice_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='bob_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' id='push1f244748d70565e9' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item ask='subscribe' subscription='from' jid='alice_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='alicE_befriend_and_alienate_1608@domain.example.com/res1' to='bob_befriend_and_alienate_1608@domain.example.com/res1' xml:lang='en'/>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='bob_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' id='pushe5a920dc9d27b469' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='both' jid='alice_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='alice_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' type='subscribed'/>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='alicE_befriend_and_alienate_1608@domain.example.com/res1' to='bob_befriend_and_alienate_1608@domain.example.com/res1' type='unavailable'/>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='bob_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' id='push48ea730462cd3eab' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='to' jid='alice_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='alice_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' type='unsubscribe'/>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='bob_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' id='push1b4a719c2e041b64' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='none' jid='alice_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<presence from='alice_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' type='unsubscribed'/>



*** User 2022-02-02 15:15:02.777 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
<iq from='bob_befriend_and_alienate_1608@domain.example.com' to='bob_befriend_and_alienate_1608@domain.example.com/res1' id='push15d09523575ce6aa' type='set'>
	<query xmlns='jabber:iq:roster'>
		<item subscription='remove' jid='alice_befriend_and_alienate_1608@domain.example.com'/>
	</query>
</iq>



*** User 2022-02-02 15:15:07.778 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 out
</stream:stream>

*** User 2022-02-02 15:15:07.778 ***
bOb_befriend_and_alienate_1608@domain.example.com/res1 in
</stream:stream>

*** User 2022-02-02 15:15:07.778 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 out
</stream:stream>

*** User 2022-02-02 15:15:07.779 ***
alicE_befriend_and_alienate_1608@domain.example.com/res1 in
</stream:stream>
*** CT 2022-02-02 15:15:07.791 *** View log from node ejabberd2@localhost when finished ejabberd2@localhost_628.html
*** CT 2022-02-02 15:15:07.792 *** View log from node mongooseim@localhost when finished mongooseim@localhost_2433.html



=== Ended at 2022-02-02 15:15:07
=== successfully completed test case
=== === Returned value: ok