=== Test case: rest_client_SUITE:roster_errors/1 (click for source code)

=== Config value:

    [{watchdog,<0.89321.0>},
     {muc_light_host,<<"muclight.localhost">>},
     {mam_backend,rdbms},
     {preset,"mysql_redis"},
     {mim_data_dir,"/home/circleci/project/big_tests/tests/rest_client_SUITE_data"},
     {tc_logfile,"/home/circleci/project/big_tests/ct_report/ct_run.test@de34115c687f.2024-04-10_12.44.09/big_tests.tests.rest_client_SUITE.logs/run.2024-04-10_12.58.39/rest_client_suite.roster_errors.112004.html"},
     {tc_group_properties,[{name,roster},parallel]},
     {tc_group_path,[]},
     {data_dir,"/home/circleci/project/big_tests/_build/default/lib/mongoose_tests/ebin/rest_client_SUITE_data/"},
     {priv_dir,"/home/circleci/project/big_tests/ct_report/ct_run.test@de34115c687f.2024-04-10_12.44.09/big_tests.tests.rest_client_SUITE.logs/run.2024-04-10_12.58.39/log_private/"},
     {{saved_modules,mongooseim@localhost,<<"localhost">>},
      #{mod_vcard =>
            #{matches => 30,
              host => {prefix,<<"vjud.">>},
              search => true,iqdisc => parallel,backend => rdbms},
        mod_roster =>
            #{iqdisc => one_queue,backend => rdbms,versioning => false,
              store_current_id => false},
        mod_register =>
            #{access => register,iqdisc => one_queue,
              registration_watchers => [],password_strength => 0,
              ip_access => [{allow,"127.0.0.0/8"},{deny,"0.0.0.0/0"}]},
        mod_sic => #{iqdisc => one_queue},
        mod_amp => #{},mod_presence => #{},
        mod_disco =>
            #{iqdisc => one_queue,users_can_see_hidden_services => false,
              server_info => [],extra_domains => []},
        mod_adhoc => #{iqdisc => one_queue,report_commands_node => false},
        mod_stream_management =>
            #{buffer => true,ack => true,
              stale_h =>
                  #{enabled => false,repeat_after => 1800,geriatric => 3600},
              backend => mnesia,buffer_max => 100,ack_freq => 1,
              resume_timeout => 600},
        mod_cache_users =>
            #{strategy => fifo,number_of_segments => 5,time_to_live => 2},
        mod_bosh =>
            #{backend => mnesia,inactivity => 30,max_pause => 120,
              max_wait => infinity,server_acks => false},
        mod_carboncopy => #{iqdisc => no_queue}}}]

=== Current directory is "/home/circleci/project/big_tests/ct_report/ct_run.test@de34115c687f.2024-04-10_12.44.09"

=== Started at 2024-04-10 12:58:41


*** CT 2024-04-10 12:58:41.465 *** View log from node mongooseim@localhost when started🔗 mongooseim@localhost_4739.html

*** User 2024-04-10 12:58:41.477 ***🔗
alicE_roster_errors_3233@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2024-04-10 12:58:41.477 ***🔗
alicE_roster_errors_3233@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='6d4f2fd80f9cac1f' from='localhost' version='1.0' xml:lang='en'>

*** User 2024-04-10 12:58:41.478 ***🔗
alicE_roster_errors_3233@localhost/res1 in
<stream:features>
	<register xmlns='http://jabber.org/features/iq-register'/>
	<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>
	<mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
		<mechanism>SCRAM-SHA-256</mechanism>
		<mechanism>PLAIN</mechanism>
	</mechanisms>
	<amp xmlns='http://jabber.org/feature/amp'/>
	<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>



*** User 2024-04-10 12:58:41.478 ***🔗
alicE_roster_errors_3233@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGFsaWNFX3Jvc3Rlcl9lcnJvcnNfMzIzMwBtYXR5Z3J5c2E=</auth>



*** User 2024-04-10 12:58:41.479 ***🔗
alicE_roster_errors_3233@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>



*** User 2024-04-10 12:58:41.479 ***🔗
alicE_roster_errors_3233@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2024-04-10 12:58:41.479 ***🔗
alicE_roster_errors_3233@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='94fc612bf667074b' from='localhost' version='1.0' xml:lang='en' to='alice_roster_errors_3233@localhost'>

*** User 2024-04-10 12:58:41.479 ***🔗
alicE_roster_errors_3233@localhost/res1 in
<stream:features>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'/>
	<register xmlns='http://jabber.org/features/iq-register'/>
	<amp xmlns='http://jabber.org/feature/amp'/>
	<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>



*** User 2024-04-10 12:58:41.479 ***🔗
alicE_roster_errors_3233@localhost/res1 out
<iq type='set' id='cabf990cd028b5db790272c31b085903'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2024-04-10 12:58:41.479 ***🔗
alicE_roster_errors_3233@localhost/res1 in
<iq id='cabf990cd028b5db790272c31b085903' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>alice_roster_errors_3233@localhost/res1</jid>
	</bind>
</iq>



*** User 2024-04-10 12:58:41.479 ***🔗
alice_roster_errors_3233@localhost/res1 out
<iq type='set' id='372746f206bc17a405fd65af578bd737'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2024-04-10 12:58:41.480 ***🔗
alice_roster_errors_3233@localhost/res1 in
<iq from='localhost' to='alice_roster_errors_3233@localhost/res1' id='372746f206bc17a405fd65af578bd737' type='result'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2024-04-10 12:58:41.480 ***🔗
alice_roster_errors_3233@localhost/res1 out
<presence/>



*** User 2024-04-10 12:58:41.482 ***🔗
alice_roster_errors_3233@localhost/res1 in
<presence from='alice_roster_errors_3233@localhost/res1' to='alice_roster_errors_3233@localhost/res1'/>



*** User 2024-04-10 12:58:41.483 ***🔗
bOb_roster_errors_3233@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2024-04-10 12:58:41.483 ***🔗
bOb_roster_errors_3233@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='4df294bbee2b7921' from='localhost' version='1.0' xml:lang='en'>

*** User 2024-04-10 12:58:41.483 ***🔗
bOb_roster_errors_3233@localhost/res1 in
<stream:features>
	<register xmlns='http://jabber.org/features/iq-register'/>
	<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>
	<mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
		<mechanism>SCRAM-SHA-256</mechanism>
		<mechanism>PLAIN</mechanism>
	</mechanisms>
	<amp xmlns='http://jabber.org/feature/amp'/>
	<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>



*** User 2024-04-10 12:58:41.483 ***🔗
bOb_roster_errors_3233@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGJPYl9yb3N0ZXJfZXJyb3JzXzMyMzMAbWFrcm9saWth</auth>



*** User 2024-04-10 12:58:41.484 ***🔗
bOb_roster_errors_3233@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>



*** User 2024-04-10 12:58:41.484 ***🔗
bOb_roster_errors_3233@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>

*** User 2024-04-10 12:58:41.484 ***🔗
bOb_roster_errors_3233@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='4cccf4ac6ba14840' from='localhost' version='1.0' xml:lang='en' to='bob_roster_errors_3233@localhost'>

*** User 2024-04-10 12:58:41.484 ***🔗
bOb_roster_errors_3233@localhost/res1 in
<stream:features>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'/>
	<register xmlns='http://jabber.org/features/iq-register'/>
	<amp xmlns='http://jabber.org/feature/amp'/>
	<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>



*** User 2024-04-10 12:58:41.484 ***🔗
bOb_roster_errors_3233@localhost/res1 out
<iq type='set' id='7a1c25c7a365b5237ada778890591833'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2024-04-10 12:58:41.485 ***🔗
bOb_roster_errors_3233@localhost/res1 in
<iq id='7a1c25c7a365b5237ada778890591833' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>bob_roster_errors_3233@localhost/res1</jid>
	</bind>
</iq>



*** User 2024-04-10 12:58:41.485 ***🔗
bob_roster_errors_3233@localhost/res1 out
<iq type='set' id='cd1d8c993944e8b86fa040fe3b60762e'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2024-04-10 12:58:41.486 ***🔗
bob_roster_errors_3233@localhost/res1 in
<iq from='localhost' to='bob_roster_errors_3233@localhost/res1' id='cd1d8c993944e8b86fa040fe3b60762e' type='result'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2024-04-10 12:58:41.486 ***🔗
bob_roster_errors_3233@localhost/res1 out
<presence/>



*** User 2024-04-10 12:58:41.487 ***🔗
bob_roster_errors_3233@localhost/res1 in
<presence from='bob_roster_errors_3233@localhost/res1' to='bob_roster_errors_3233@localhost/res1'/>



*** User 2024-04-10 12:58:41.494 ***🔗
REST request fails:
Code: 400
Req: {<0.89387.0>,<<"/api/contacts">>,<<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"0421ae47ee7fecd2">>},
       {<<"authorization">>,
        <<"Basic Ym9iX3Jvc3Rlcl9lcnJvcnNfMzIzM0Bsb2NhbGhvc3Q6bWFrcm9saWth">>}],
      <<"{}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 10 Apr 2024 12:58:40 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"13">>}],
         <<"\"Missing JID\"">>,146,1583}
Params: #{path => <<"/api/contacts">>,
          server => #{node => mongooseim@localhost},
          creds => {<<"bob_roster_errors_3233@localhost">>,<<"makrolika">>},
          method => <<"POST">>,role => client,body => <<"{}">>,
          return_headers => true}


*** User 2024-04-10 12:58:41.500 ***🔗
REST request fails:
Code: 400
Req: {<0.89413.0>,<<"/api/contacts">>,<<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"52b6890885973ce7">>},
       {<<"authorization">>,
        <<"Basic Ym9iX3Jvc3Rlcl9lcnJvcnNfMzIzM0Bsb2NhbGhvc3Q6bWFrcm9saWth">>}],
      <<"{\"jid\":\"@invalid\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 10 Apr 2024 12:58:40 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"23">>}],
         <<"\"Invalid JID: @invalid\"">>,156,881}
Params: #{path => <<"/api/contacts">>,
          server => #{node => mongooseim@localhost},
          creds => {<<"bob_roster_errors_3233@localhost">>,<<"makrolika">>},
          method => <<"POST">>,role => client,
          body => <<"{\"jid\":\"@invalid\"}">>,return_headers => true}


*** User 2024-04-10 12:58:41.505 ***🔗
REST request fails:
Code: 400
Req: {<0.89439.0>,<<"/api/contacts/alice_roster_errors_3233@localhost">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"ab1e85d40a2cdabf">>},
       {<<"authorization">>,
        <<"Basic Ym9iX3Jvc3Rlcl9lcnJvcnNfMzIzM0Bsb2NhbGhvc3Q6bWFrcm9saWth">>}],
      <<"{\"action\":\"nosuchaction\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 10 Apr 2024 12:58:40 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"16">>}],
         <<"\"Invalid action\"">>,149,863}
Params: #{path => <<"/api/contacts/alice_roster_errors_3233@localhost">>,
          server => #{node => mongooseim@localhost},
          creds => {<<"bob_roster_errors_3233@localhost">>,<<"makrolika">>},
          method => <<"PUT">>,role => client,
          body => <<"{\"action\":\"nosuchaction\"}">>,return_headers => true}


*** User 2024-04-10 12:58:41.512 ***🔗
REST request fails:
Code: 400
Req: {<0.89452.0>,<<"/api/contacts/alice_roster_errors_3233@localhost">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"f0c25f3bf31d8dfb">>},
       {<<"authorization">>,
        <<"Basic Ym9iX3Jvc3Rlcl9lcnJvcnNfMzIzM0Bsb2NhbGhvc3Q6bWFrcm9saWth">>}],
      <<"{}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 10 Apr 2024 12:58:40 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"16">>}],
         <<"\"Missing action\"">>,149,1551}
Params: #{path => <<"/api/contacts/alice_roster_errors_3233@localhost">>,
          server => #{node => mongooseim@localhost},
          creds => {<<"bob_roster_errors_3233@localhost">>,<<"makrolika">>},
          method => <<"PUT">>,role => client,body => <<"{}">>,
          return_headers => true}


*** User 2024-04-10 12:58:41.518 ***🔗
REST request fails:
Code: 404
Req: {<0.89482.0>,<<"/api/contacts">>,<<"POST">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"8a8b4f35eee8107f">>},
       {<<"authorization">>,
        <<"Basic Ym9iX3Jvc3Rlcl9lcnJvcnNfMzIzM0Bsb2NhbGhvc3Q6bWFrcm9saWth">>}],
      <<"{\"jid\":\"zorro@localhost\"}">>}
Result: {{<<"404">>,<<"Not Found">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 10 Apr 2024 12:58:40 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"41">>}],
         <<"\"The user zorro@localhost does not exist\"">>,172,1670}
Params: #{path => <<"/api/contacts">>,
          server => #{node => mongooseim@localhost},
          creds => {<<"bob_roster_errors_3233@localhost">>,<<"makrolika">>},
          method => <<"POST">>,role => client,
          body => <<"{\"jid\":\"zorro@localhost\"}">>,return_headers => true}


*** User 2024-04-10 12:58:41.569 ***🔗
REST request fails:
Code: 404
Req: {<0.89512.0>,<<"/api/contacts/zorro@localhost">>,<<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"54aeedbc6c77705a">>},
       {<<"authorization">>,
        <<"Basic Ym9iX3Jvc3Rlcl9lcnJvcnNfMzIzM0Bsb2NhbGhvc3Q6bWFrcm9saWth">>}],
      <<"{\"action\":\"invite\"}">>}
Result: {{<<"404">>,<<"Not Found">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 10 Apr 2024 12:58:40 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"30">>}],
         <<"\"Given contact does not exist\"">>,161,1264}
Params: #{path => <<"/api/contacts/zorro@localhost">>,
          server => #{node => mongooseim@localhost},
          creds => {<<"bob_roster_errors_3233@localhost">>,<<"makrolika">>},
          method => <<"PUT">>,role => client,
          body => <<"{\"action\":\"invite\"}">>,return_headers => true}


*** User 2024-04-10 12:58:41.576 ***🔗
REST request fails:
Code: 404
Req: {<0.89525.0>,<<"/api/contacts/zorro@localhost">>,<<"GET">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"af83cf02f1880a1b">>},
       {<<"authorization">>,
        <<"Basic Ym9iX3Jvc3Rlcl9lcnJvcnNfMzIzM0Bsb2NhbGhvc3Q6bWFrcm9saWth">>}],
      <<>>}
Result: {{<<"404">>,<<"Not Found">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 10 Apr 2024 12:58:40 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"32">>}],
         <<"\"JID provided but not supported\"">>,163,943}
Params: #{path => <<"/api/contacts/zorro@localhost">>,
          server => #{node => mongooseim@localhost},
          creds => {<<"bob_roster_errors_3233@localhost">>,<<"makrolika">>},
          method => <<"GET">>,role => client,body => <<>>,
          return_headers => true}


*** User 2024-04-10 12:58:41.582 ***🔗
REST request fails:
Code: 404
Req: {<0.89551.0>,<<"/api/contacts/zorro@localhost">>,<<"DELETE">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"3fb17bd537b6b22b">>},
       {<<"authorization">>,
        <<"Basic Ym9iX3Jvc3Rlcl9lcnJvcnNfMzIzM0Bsb2NhbGhvc3Q6bWFrcm9saWth">>}],
      <<>>}
Result: {{<<"404">>,<<"Not Found">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Wed, 10 Apr 2024 12:58:41 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"59">>}],
         <<"\"Cannot remove zorro@localhost contact that does not exist\"">>,
         190,1554}
Params: #{path => <<"/api/contacts/zorro@localhost">>,
          server => #{node => mongooseim@localhost},
          creds => {<<"bob_roster_errors_3233@localhost">>,<<"makrolika">>},
          method => <<"DELETE">>,role => client,body => <<>>,
          return_headers => true}


*** User 2024-04-10 12:58:41.582 ***🔗
bob_roster_errors_3233@localhost/res1 out
</stream:stream>

*** User 2024-04-10 12:58:41.582 ***🔗
bob_roster_errors_3233@localhost/res1 in
</stream:stream>

*** User 2024-04-10 12:58:41.582 ***🔗
alice_roster_errors_3233@localhost/res1 out
</stream:stream>

*** User 2024-04-10 12:58:41.582 ***🔗
alice_roster_errors_3233@localhost/res1 in
</stream:stream>
*** CT 2024-04-10 12:58:41.585 *** View log from node mongooseim@localhost when finished🔗 mongooseim@localhost_4739.html



=== Ended at 2024-04-10 12:58:41
=== successfully completed test case
=== === Returned value: ok