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

=== Config value:

    [{watchdog,<0.71879.0>},
     {{ejabberd_cwd,mongooseim@localhost},
      "/home/circleci/project/_build/mim1/rel/mongooseim"},
     {mam_backend,disabled},
     {preset,"internal_mnesia"},
     {mim_data_dir,"/home/circleci/project/big_tests/tests/rest_SUITE_data"},
     {tc_logfile,"/home/circleci/project/big_tests/ct_report/ct_run.test@6b87bb397ec6.2024-04-16_10.12.53/big_tests.tests.rest_SUITE.logs/run.2024-04-16_10.29.10/rest_suite.subscription_errors.172290.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@6b87bb397ec6.2024-04-16_10.12.53/big_tests.tests.rest_SUITE.logs/run.2024-04-16_10.29.10/log_private/"},
     {{saved_modules,mongooseim@localhost,<<"localhost">>},
      #{mod_vcard =>
            #{matches => 30,
              host => {prefix,<<"vjud.">>},
              search => true,backend => mnesia,iqdisc => parallel},
        mod_roster =>
            #{backend => mnesia,iqdisc => one_queue,versioning => false,
              store_current_id => false},
        mod_sic => #{iqdisc => one_queue},
        mod_amp => #{},
        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_presence => #{},
        mod_disco =>
            #{iqdisc => one_queue,server_info => [],extra_domains => [],
              users_can_see_hidden_services => false},
        mod_stream_management =>
            #{buffer => true,ack => true,backend => mnesia,buffer_max => 100,
              ack_freq => 1,
              stale_h =>
                  #{enabled => false,repeat_after => 1800,geriatric => 3600},
              resume_timeout => 600},
        mod_adhoc => #{iqdisc => one_queue,report_commands_node => false},
        mod_bosh =>
            #{backend => mnesia,inactivity => 30,max_pause => 120,
              max_wait => infinity,server_acks => false},
        mod_cache_users =>
            #{strategy => fifo,number_of_segments => 5,time_to_live => 2},
        mod_carboncopy => #{iqdisc => no_queue}}},
     {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@6b87bb397ec6.2024-04-16_10.12.53"

=== Started at 2024-04-16 10:29:10


*** CT 2024-04-16 10:29:10.814 *** View log from node mongooseim@localhost when started🔗 mongooseim@localhost_4575.html

*** User 2024-04-16 10:29:10.834 ***🔗
REST request fails:
Code: 400
Req: {<0.71958.0>,
      <<"/api/contacts/alicE_subscription_errors_2479@localhost/@invalid_jid">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"2dfeaaec9c3a9ad2">>}],
      <<"{\"action\":\"subscribe\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"21">>}],
         <<"\"Invalid contact JID\"">>,154,961}
Params: #{path =>
              <<"/api/contacts/alicE_subscription_errors_2479@localhost/@invalid_jid">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,
          body => <<"{\"action\":\"subscribe\"}">>,return_headers => true}


*** User 2024-04-16 10:29:10.837 ***🔗
REST request fails:
Code: 400
Req: {<0.71966.0>,
      <<"/api/contacts/@invalid_jid/bOb_subscription_errors_2479@localhost">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"287143cf7c6407cc">>}],
      <<"{\"action\":\"subscribe\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"18">>}],
         <<"\"Invalid user JID\"">>,151,799}
Params: #{path =>
              <<"/api/contacts/@invalid_jid/bOb_subscription_errors_2479@localhost">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,
          body => <<"{\"action\":\"subscribe\"}">>,return_headers => true}


*** User 2024-04-16 10:29:10.839 ***🔗
REST request fails:
Code: 400
Req: {<0.71969.0>,
      <<"/api/contacts/alicE_subscription_errors_2479@localhost/bOb_subscription_errors_2479@localhost">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"645b6625f1128bd3">>}],
      <<"{}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"16">>}],
         <<"\"Missing action\"">>,149,634}
Params: #{path =>
              <<"/api/contacts/alicE_subscription_errors_2479@localhost/bOb_subscription_errors_2479@localhost">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,body => <<"{}">>,
          return_headers => true}


*** User 2024-04-16 10:29:10.842 ***🔗
REST request fails:
Code: 400
Req: {<0.71977.0>,
      <<"/api/contacts/alicE_subscription_errors_2479@localhost/bOb_subscription_errors_2479@localhost/manage">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"5cc92a8b8c110dcd">>}],
      <<"{}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"16">>}],
         <<"\"Missing action\"">>,149,826}
Params: #{path =>
              <<"/api/contacts/alicE_subscription_errors_2479@localhost/bOb_subscription_errors_2479@localhost/manage">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,body => <<"{}">>,
          return_headers => true}


*** User 2024-04-16 10:29:10.844 ***🔗
REST request fails:
Code: 400
Req: {<0.71990.0>,
      <<"/api/contacts/alicE_subscription_errors_2479@localhost/bOb_subscription_errors_2479@localhost">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"752d37a363e73b13">>}],
      <<"{\"action\":\"something stupid\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"16">>}],
         <<"\"Invalid action\"">>,149,732}
Params: #{path =>
              <<"/api/contacts/alicE_subscription_errors_2479@localhost/bOb_subscription_errors_2479@localhost">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,
          body => <<"{\"action\":\"something stupid\"}">>,
          return_headers => true}


*** User 2024-04-16 10:29:10.846 ***🔗
REST request fails:
Code: 400
Req: {<0.71998.0>,
      <<"/api/contacts/alicE_subscription_errors_2479@localhost/bOb_subscription_errors_2479@localhost/manage">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"f54798c62592f64f">>}],
      <<"{\"action\":\"off with his head\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"16">>}],
         <<"\"Invalid action\"">>,149,667}
Params: #{path =>
              <<"/api/contacts/alicE_subscription_errors_2479@localhost/bOb_subscription_errors_2479@localhost/manage">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,
          body => <<"{\"action\":\"off with his head\"}">>,
          return_headers => true}


*** User 2024-04-16 10:29:10.849 ***🔗
REST request fails:
Code: 400
Req: {<0.72004.0>,
      <<"/api/contacts/@invalid/bOb_subscription_errors_2479@localhost/manage">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"46e2929cd9cd1181">>}],
      <<"{\"action\":\"connect\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"18">>}],
         <<"\"Invalid user JID\"">>,151,684}
Params: #{path =>
              <<"/api/contacts/@invalid/bOb_subscription_errors_2479@localhost/manage">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,
          body => <<"{\"action\":\"connect\"}">>,return_headers => true}


*** User 2024-04-16 10:29:10.851 ***🔗
REST request fails:
Code: 400
Req: {<0.72013.0>,
      <<"/api/contacts/alicE_subscription_errors_2479@localhost/@bzzz/manage">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"f3baaede6df6b601">>}],
      <<"{\"action\":\"connect\"}">>}
Result: {{<<"400">>,<<"Bad Request">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"21">>}],
         <<"\"Invalid contact JID\"">>,154,720}
Params: #{path =>
              <<"/api/contacts/alicE_subscription_errors_2479@localhost/@bzzz/manage">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,
          body => <<"{\"action\":\"connect\"}">>,return_headers => true}


*** User 2024-04-16 10:29:10.857 ***🔗
REST request fails:
Code: 404
Req: {<0.72019.0>,
      <<"/api/contacts/alicE_subscription_errors_2479@localhost/baduser@baddomain/manage">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"f2b3b732f1a9daa8">>}],
      <<"{\"action\":\"connect\"}">>}
Result: {{<<"404">>,<<"Not Found">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"43">>}],
         <<"\"The user baduser@baddomain does not exist\"">>,174,4951}
Params: #{path =>
              <<"/api/contacts/alicE_subscription_errors_2479@localhost/baduser@baddomain/manage">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,
          body => <<"{\"action\":\"connect\"}">>,return_headers => true}


*** User 2024-04-16 10:29:10.860 ***🔗
REST request fails:
Code: 404
Req: {<0.72025.0>,
      <<"/api/contacts/baduser@baddomain/alicE_subscription_errors_2479@localhost/manage">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"e34d28cacee3fef0">>}],
      <<"{\"action\":\"connect\"}">>}
Result: {{<<"404">>,<<"Not Found">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"18">>}],
         <<"\"Domain not found\"">>,149,947}
Params: #{path =>
              <<"/api/contacts/baduser@baddomain/alicE_subscription_errors_2479@localhost/manage">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,
          body => <<"{\"action\":\"connect\"}">>,return_headers => true}


*** User 2024-04-16 10:29:10.866 ***🔗
REST request fails:
Code: 404
Req: {<0.72029.0>,
      <<"/api/contacts/alicE_subscription_errors_2479@localhost/baduser@localhost/manage">>,
      <<"PUT">>,
      [{<<"Content-Type">>,<<"application/json">>},
       {<<"Request-Id">>,<<"113f779aaae43ab4">>}],
      <<"{\"action\":\"disconnect\"}">>}
Result: {{<<"404">>,<<"Not Found">>},
         [{<<"server">>,<<"Cowboy">>},
          {<<"date">>,<<"Tue, 16 Apr 2024 10:29:10 GMT">>},
          {<<"content-type">>,<<"application/json">>},
          {<<"content-length">>,<<"61">>}],
         <<"\"Cannot remove baduser@localhost contact that does not exist\"">>,
         192,911}
Params: #{path =>
              <<"/api/contacts/alicE_subscription_errors_2479@localhost/baduser@localhost/manage">>,
          server => #{node => mongooseim@localhost},
          role => admin,method => <<"PUT">>,
          body => <<"{\"action\":\"disconnect\"}">>,return_headers => true}

*** CT 2024-04-16 10:29:10.870 *** View log from node mongooseim@localhost when finished🔗 mongooseim@localhost_4575.html



=== Ended at 2024-04-16 10:29:10
=== successfully completed test case
=== === Returned value: {{<<"404">>,<<"Not Found">>},
                     <<"Cannot remove baduser@localhost contact that does not exist">>}