@@ -111,40 +111,6 @@ def test_delivery_status_failed(acfactory: ACFactory) -> None:
111111 assert failing_message .get_snapshot ().state == const .MessageState .OUT_FAILED
112112
113113
114- def test_download_on_demand (acfactory : ACFactory ) -> None :
115- """
116- Test if download on demand emits chatlist update events.
117- This is only needed for last message in chat, but finding that out is too expensive, so it's always emitted
118- """
119- alice , bob = acfactory .get_online_accounts (2 )
120-
121- alice_contact_bob = alice .create_contact (bob , "Bob" )
122- alice_chat_bob = alice_contact_bob .create_chat ()
123- alice_chat_bob .send_text ("hi" )
124-
125- alice .set_config ("download_limit" , "1" )
126-
127- msg = bob .wait_for_incoming_msg ()
128- chat_id = msg .get_snapshot ().chat_id
129- msg .get_snapshot ().chat .accept ()
130- bob .get_chat_by_id (chat_id ).send_message (
131- "Hello World, this message is bigger than 5 bytes" ,
132- html = base64 .b64encode (os .urandom (300000 )).decode ("utf-8" ),
133- )
134-
135- message = alice .wait_for_incoming_msg ()
136- snapshot = message .get_snapshot ()
137- assert snapshot .download_state == const .DownloadState .AVAILABLE
138-
139- alice .clear_all_events ()
140-
141- snapshot = message .get_snapshot ()
142- chat_id = snapshot .chat_id
143- alice ._rpc .download_full_message (alice .id , message .id )
144-
145- wait_for_chatlist_specific_item (alice , chat_id )
146-
147-
148114def get_multi_account_test_setup (acfactory : ACFactory ) -> [Account , Account , Account ]:
149115 alice , bob = acfactory .get_online_accounts (2 )
150116
0 commit comments