=== Test case: inbox_SUITE:user_has_two_unread_messages/1 (click for source code)

=== Config value:

    [{watchdog,<0.35005.0>},
     {inbox_opts,#{max_result_limit => infinity,
                   groupchat => [muclight],
                   iqdisc => no_queue,backend => rdbms,
                   delete_domain_limit => infinity,
                   async_writer => #{pool_size => 8},
                   boxes => [<<"inbox">>,<<"archive">>,<<"bin">>,<<"other">>],
                   bin_ttl => 30,bin_clean_after => 3600000,
                   reset_markers => [<<"displayed">>],
                   aff_changes => true,remove_on_kicked => true}},
     {preset,"pgsql_cets"},
     {mim_data_dir,"/home/circleci/project/big_tests/tests/inbox_SUITE_data"},
     {tc_logfile,"/home/circleci/project/big_tests/ct_report/ct_run.test@e06ff82a20fb.2024-03-21_07.45.38/big_tests.tests.inbox_SUITE.logs/run.2024-03-21_07.53.21/inbox_suite.user_has_two_unread_messages.52867.html"},
     {tc_group_properties,[{name,one_to_one},parallel]},
     {tc_group_path,[[{name,regular}]]},
     {data_dir,"/home/circleci/project/big_tests/_build/default/lib/mongoose_tests/ebin/inbox_SUITE_data/"},
     {priv_dir,"/home/circleci/project/big_tests/ct_report/ct_run.test@e06ff82a20fb.2024-03-21_07.45.38/big_tests.tests.inbox_SUITE.logs/run.2024-03-21_07.53.21/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_amp => #{},
        mod_sic => #{iqdisc => one_queue},
        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_disco =>
            #{iqdisc => one_queue,server_info => [],extra_domains => [],
              users_can_see_hidden_services => false},
        mod_presence => #{},
        mod_stream_management =>
            #{buffer => true,ack => true,backend => cets,
              stale_h =>
                  #{enabled => false,repeat_after => 1800,geriatric => 3600},
              buffer_max => 100,ack_freq => 1,resume_timeout => 600},
        mod_adhoc => #{iqdisc => one_queue,report_commands_node => false},
        mod_cache_users =>
            #{strategy => fifo,number_of_segments => 5,time_to_live => 2},
        mod_bosh =>
            #{backend => cets,inactivity => 30,max_pause => 120,
              max_wait => infinity,server_acks => false},
        mod_carboncopy => #{iqdisc => no_queue}}},
     {{saved_modules,mongooseim@localhost,<<"localhost.bis">>},
      #{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_amp => #{},
        mod_sic => #{iqdisc => one_queue},
        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_disco =>
            #{iqdisc => one_queue,server_info => [],extra_domains => [],
              users_can_see_hidden_services => false},
        mod_presence => #{},
        mod_stream_management =>
            #{buffer => true,ack => true,backend => cets,
              stale_h =>
                  #{enabled => false,repeat_after => 1800,geriatric => 3600},
              buffer_max => 100,ack_freq => 1,resume_timeout => 600},
        mod_adhoc => #{iqdisc => one_queue,report_commands_node => false},
        mod_cache_users =>
            #{strategy => fifo,number_of_segments => 5,time_to_live => 2},
        mod_bosh =>
            #{backend => cets,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@e06ff82a20fb.2024-03-21_07.45.38"

=== Started at 2024-03-21 07:53:22


*** CT 2024-03-21 07:53:22.270 *** View log from node mongooseim@localhost when started🔗 mongooseim@localhost_2745.html

*** User 2024-03-21 07:53:22.302 ***🔗
kate_user_has_two_unread_messages_1455@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-03-21 07:53:22.303 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='a2bd5d38fcbd9630' from='localhost' version='1.0' xml:lang='en'>

*** User 2024-03-21 07:53:22.304 ***🔗
kate_user_has_two_unread_messages_1455@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-03-21 07:53:22.304 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGthdGVfdXNlcl9oYXNfdHdvX3VucmVhZF9tZXNzYWdlc18xNDU1AG1ha3Jvd2U7cA==</auth>



*** User 2024-03-21 07:53:22.309 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>



*** User 2024-03-21 07:53:22.309 ***🔗
kate_user_has_two_unread_messages_1455@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-03-21 07:53:22.310 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='dbca32ede74fc8b9' from='localhost' version='1.0' xml:lang='en' to='kate_user_has_two_unread_messages_1455@localhost'>

*** User 2024-03-21 07:53:22.310 ***🔗
kate_user_has_two_unread_messages_1455@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-03-21 07:53:22.310 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 out
<iq type='set' id='fff35c551723b53233d2d83543cdf441'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2024-03-21 07:53:22.310 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 in
<iq id='fff35c551723b53233d2d83543cdf441' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>kate_user_has_two_unread_messages_1455@localhost/res1</jid>
	</bind>
</iq>



*** User 2024-03-21 07:53:22.310 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 out
<iq type='set' id='5f434d7a6b4d41882a33e8f71838779a'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2024-03-21 07:53:22.312 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 in
<iq from='localhost' to='kate_user_has_two_unread_messages_1455@localhost/res1' id='5f434d7a6b4d41882a33e8f71838779a' type='result'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2024-03-21 07:53:22.312 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 out
<presence/>



*** User 2024-03-21 07:53:22.372 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 in
<presence from='kate_user_has_two_unread_messages_1455@localhost/res1' to='kate_user_has_two_unread_messages_1455@localhost/res1'/>



*** User 2024-03-21 07:53:22.375 ***🔗
mike_user_has_two_unread_messages_1455@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-03-21 07:53:22.378 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='e65d7f0f0563de49' from='localhost' version='1.0' xml:lang='en'>

*** User 2024-03-21 07:53:22.378 ***🔗
mike_user_has_two_unread_messages_1455@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-03-21 07:53:22.378 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AG1pa2VfdXNlcl9oYXNfdHdvX3VucmVhZF9tZXNzYWdlc18xNDU1AG5pY25pZW1h</auth>



*** User 2024-03-21 07:53:22.388 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>



*** User 2024-03-21 07:53:22.388 ***🔗
mike_user_has_two_unread_messages_1455@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-03-21 07:53:22.388 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='a524b437b407b135' from='localhost' version='1.0' xml:lang='en' to='mike_user_has_two_unread_messages_1455@localhost'>

*** User 2024-03-21 07:53:22.389 ***🔗
mike_user_has_two_unread_messages_1455@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-03-21 07:53:22.390 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 out
<iq type='set' id='275f4b3c98a0b8f8c2e0d3da254ad8e0'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<resource>res1</resource>
	</bind>
</iq>



*** User 2024-03-21 07:53:22.391 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
<iq id='275f4b3c98a0b8f8c2e0d3da254ad8e0' type='result'>
	<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
		<jid>mike_user_has_two_unread_messages_1455@localhost/res1</jid>
	</bind>
</iq>



*** User 2024-03-21 07:53:22.391 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 out
<iq type='set' id='e4ba61ed03970d6fa2ddc8185bac93fe'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2024-03-21 07:53:22.404 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
<iq from='localhost' to='mike_user_has_two_unread_messages_1455@localhost/res1' id='e4ba61ed03970d6fa2ddc8185bac93fe' type='result'>
	<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>



*** User 2024-03-21 07:53:22.404 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 out
<presence/>



*** User 2024-03-21 07:53:22.439 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
<presence from='mike_user_has_two_unread_messages_1455@localhost/res1' to='mike_user_has_two_unread_messages_1455@localhost/res1'/>



*** User 2024-03-21 07:53:22.439 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 out
<message type='chat' to='mike_user_has_two_unread_messages_1455@localhost/res1' id='fe3934dc50f07c682ea44b73c65fea1a'>
	<body>Hello</body>
</message>



*** User 2024-03-21 07:53:22.443 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
<message from='kate_user_has_two_unread_messages_1455@localhost/res1' to='mike_user_has_two_unread_messages_1455@localhost/res1' type='chat' id='fe3934dc50f07c682ea44b73c65fea1a'>
	<body>Hello</body>
</message>



*** User 2024-03-21 07:53:22.443 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 out
<message type='chat' to='mike_user_has_two_unread_messages_1455@localhost/res1' id='c7d0a45e4f57bf526fed0e78a5507d24'>
	<body>How are you</body>
</message>



*** User 2024-03-21 07:53:22.462 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
<message from='kate_user_has_two_unread_messages_1455@localhost/res1' to='mike_user_has_two_unread_messages_1455@localhost/res1' type='chat' id='c7d0a45e4f57bf526fed0e78a5507d24'>
	<body>How are you</body>
</message>



*** User 2024-03-21 07:53:22.462 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 out
<iq type='set' id='52ed2c88b0a3116fb2b94da45c3a26eb'>
	<inbox xmlns='erlang-solutions.com:xmpp:inbox:0'>
		<x xmlns='jabber:x:data' type='submit'>
			<field type='hidden' var='FORM_TYPE'>
				<value>erlang-solutions.com:xmpp:inbox:0</value>
			</field>
			<field type='text-single' var='hidden_read'>
				<value>false</value>
			</field>
		</x>
	</inbox>
</iq>



*** User 2024-03-21 07:53:22.463 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
<message from='mike_user_has_two_unread_messages_1455@localhost' to='mike_user_has_two_unread_messages_1455@localhost/res1' id='1711-7602-463332'>
	<result xmlns='erlang-solutions.com:xmpp:inbox:0' unread='2' queryid='52ed2c88b0a3116fb2b94da45c3a26eb'>
		<forwarded xmlns='urn:xmpp:forward:0'>
			<delay xmlns='urn:xmpp:delay' stamp='2024-03-21T07:53:22.444927Z'/>
			<message from='kate_user_has_two_unread_messages_1455@localhost/res1' type='chat' to='mike_user_has_two_unread_messages_1455@localhost/res1' id='c7d0a45e4f57bf526fed0e78a5507d24'>
				<body>How are you</body>
			</message>
		</forwarded>
		<read>false</read>
		<box>inbox</box>
		<archive>false</archive>
		<mute>0</mute>
	</result>
</message>



*** User 2024-03-21 07:53:22.463 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
<iq from='mike_user_has_two_unread_messages_1455@localhost' to='mike_user_has_two_unread_messages_1455@localhost/res1' id='52ed2c88b0a3116fb2b94da45c3a26eb' type='result'>
	<fin xmlns='erlang-solutions.com:xmpp:inbox:0'>
		<set xmlns='http://jabber.org/protocol/rsm'>
			<first>1711007602444927/a2F0ZV91c2VyX2hhc190d29fdW5yZWFkX21lc3NhZ2VzXzE0NTVAbG9jYWxob3N0</first>
			<last>1711007602444927/a2F0ZV91c2VyX2hhc190d29fdW5yZWFkX21lc3NhZ2VzXzE0NTVAbG9jYWxob3N0</last>
		</set>
		<active-conversations>1</active-conversations>
		<count>1</count>
		<unread-messages>2</unread-messages>
	</fin>
</iq>



*** User 2024-03-21 07:53:22.464 ***🔗
waiting for inbox_size is done in 0 miliseconds

*** User 2024-03-21 07:53:22.464 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 out
<iq type='set' id='d9454ba88367591d8c21b038d22cc9f4'>
	<inbox xmlns='erlang-solutions.com:xmpp:inbox:0'>
		<x xmlns='jabber:x:data' type='submit'>
			<field type='hidden' var='FORM_TYPE'>
				<value>erlang-solutions.com:xmpp:inbox:0</value>
			</field>
			<field type='text-single' var='hidden_read'>
				<value>false</value>
			</field>
		</x>
	</inbox>
</iq>



*** User 2024-03-21 07:53:22.466 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 in
<message from='kate_user_has_two_unread_messages_1455@localhost' to='kate_user_has_two_unread_messages_1455@localhost/res1' id='1711-7602-465902'>
	<result xmlns='erlang-solutions.com:xmpp:inbox:0' unread='0' queryid='d9454ba88367591d8c21b038d22cc9f4'>
		<forwarded xmlns='urn:xmpp:forward:0'>
			<delay xmlns='urn:xmpp:delay' stamp='2024-03-21T07:53:22.444927Z'/>
			<message from='kate_user_has_two_unread_messages_1455@localhost/res1' type='chat' to='mike_user_has_two_unread_messages_1455@localhost/res1' id='c7d0a45e4f57bf526fed0e78a5507d24'>
				<body>How are you</body>
			</message>
		</forwarded>
		<read>true</read>
		<box>inbox</box>
		<archive>false</archive>
		<mute>0</mute>
	</result>
</message>



*** User 2024-03-21 07:53:22.467 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 in
<iq from='kate_user_has_two_unread_messages_1455@localhost' to='kate_user_has_two_unread_messages_1455@localhost/res1' id='d9454ba88367591d8c21b038d22cc9f4' type='result'>
	<fin xmlns='erlang-solutions.com:xmpp:inbox:0'>
		<set xmlns='http://jabber.org/protocol/rsm'>
			<first>1711007602444927/bWlrZV91c2VyX2hhc190d29fdW5yZWFkX21lc3NhZ2VzXzE0NTVAbG9jYWxob3N0</first>
			<last>1711007602444927/bWlrZV91c2VyX2hhc190d29fdW5yZWFkX21lc3NhZ2VzXzE0NTVAbG9jYWxob3N0</last>
		</set>
		<active-conversations>0</active-conversations>
		<count>1</count>
		<unread-messages>0</unread-messages>
	</fin>
</iq>



*** User 2024-03-21 07:53:22.467 ***🔗
waiting for inbox_size is done in 0 miliseconds

*** User 2024-03-21 07:53:22.468 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 out
</stream:stream>

*** User 2024-03-21 07:53:22.468 ***🔗
mike_user_has_two_unread_messages_1455@localhost/res1 in
</stream:stream>

*** User 2024-03-21 07:53:22.469 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 out
</stream:stream>

*** User 2024-03-21 07:53:22.470 ***🔗
kate_user_has_two_unread_messages_1455@localhost/res1 in
</stream:stream>
*** CT 2024-03-21 07:53:22.483 *** View log from node mongooseim@localhost when finished🔗 mongooseim@localhost_2745.html



=== Ended at 2024-03-21 07:53:22
=== successfully completed test case
=== === Returned value: ok