@@ -66,8 +66,7 @@ mod test_chatlist_events {
6666 use crate :: {
6767 EventType ,
6868 chat:: {
69- self , ChatId , ChatVisibility , MuteDuration , create_broadcast, create_group_chat,
70- set_muted,
69+ self , ChatId , ChatVisibility , MuteDuration , create_broadcast, create_group, set_muted,
7170 } ,
7271 config:: Config ,
7372 constants:: * ,
@@ -138,7 +137,7 @@ mod test_chatlist_events {
138137 async fn test_change_chat_visibility ( ) -> Result < ( ) > {
139138 let mut tcm = TestContextManager :: new ( ) ;
140139 let alice = tcm. alice ( ) . await ;
141- let chat_id = create_group_chat ( & alice, "my_group" ) . await ?;
140+ let chat_id = create_group ( & alice, "my_group" ) . await ?;
142141
143142 chat_id
144143 . set_visibility ( & alice, ChatVisibility :: Pinned )
@@ -284,7 +283,7 @@ mod test_chatlist_events {
284283 async fn test_delete_chat ( ) -> Result < ( ) > {
285284 let mut tcm = TestContextManager :: new ( ) ;
286285 let alice = tcm. alice ( ) . await ;
287- let chat = create_group_chat ( & alice, "My Group" ) . await ?;
286+ let chat = create_group ( & alice, "My Group" ) . await ?;
288287
289288 alice. evtracker . clear_events ( ) ;
290289 chat. delete ( & alice) . await ?;
@@ -294,11 +293,11 @@ mod test_chatlist_events {
294293
295294 /// Create group chat
296295 #[ tokio:: test( flavor = "multi_thread" , worker_threads = 2 ) ]
297- async fn test_create_group_chat ( ) -> Result < ( ) > {
296+ async fn test_create_group ( ) -> Result < ( ) > {
298297 let mut tcm = TestContextManager :: new ( ) ;
299298 let alice = tcm. alice ( ) . await ;
300299 alice. evtracker . clear_events ( ) ;
301- let chat = create_group_chat ( & alice, "My Group" ) . await ?;
300+ let chat = create_group ( & alice, "My Group" ) . await ?;
302301 wait_for_chatlist_and_specific_item ( & alice, chat) . await ;
303302 Ok ( ( ) )
304303 }
@@ -319,7 +318,7 @@ mod test_chatlist_events {
319318 async fn test_mute_chat ( ) -> Result < ( ) > {
320319 let mut tcm = TestContextManager :: new ( ) ;
321320 let alice = tcm. alice ( ) . await ;
322- let chat = create_group_chat ( & alice, "My Group" ) . await ?;
321+ let chat = create_group ( & alice, "My Group" ) . await ?;
323322
324323 alice. evtracker . clear_events ( ) ;
325324 chat:: set_muted ( & alice, chat, MuteDuration :: Forever ) . await ?;
@@ -338,7 +337,7 @@ mod test_chatlist_events {
338337 async fn test_mute_chat_expired ( ) -> Result < ( ) > {
339338 let mut tcm = TestContextManager :: new ( ) ;
340339 let alice = tcm. alice ( ) . await ;
341- let chat = create_group_chat ( & alice, "My Group" ) . await ?;
340+ let chat = create_group ( & alice, "My Group" ) . await ?;
342341
343342 let mute_duration = MuteDuration :: Until (
344343 std:: time:: SystemTime :: now ( )
@@ -358,7 +357,7 @@ mod test_chatlist_events {
358357 async fn test_change_chat_name ( ) -> Result < ( ) > {
359358 let mut tcm = TestContextManager :: new ( ) ;
360359 let alice = tcm. alice ( ) . await ;
361- let chat = create_group_chat ( & alice, "My Group" ) . await ?;
360+ let chat = create_group ( & alice, "My Group" ) . await ?;
362361
363362 alice. evtracker . clear_events ( ) ;
364363 chat:: set_chat_name ( & alice, chat, "New Name" ) . await ?;
@@ -372,7 +371,7 @@ mod test_chatlist_events {
372371 async fn test_change_chat_profile_image ( ) -> Result < ( ) > {
373372 let mut tcm = TestContextManager :: new ( ) ;
374373 let alice = tcm. alice ( ) . await ;
375- let chat = create_group_chat ( & alice, "My Group" ) . await ?;
374+ let chat = create_group ( & alice, "My Group" ) . await ?;
376375
377376 alice. evtracker . clear_events ( ) ;
378377 let file = alice. dir . path ( ) . join ( "avatar.png" ) ;
@@ -445,7 +444,7 @@ mod test_chatlist_events {
445444 async fn test_delete_message ( ) -> Result < ( ) > {
446445 let mut tcm = TestContextManager :: new ( ) ;
447446 let alice = tcm. alice ( ) . await ;
448- let chat = create_group_chat ( & alice, "My Group" ) . await ?;
447+ let chat = create_group ( & alice, "My Group" ) . await ?;
449448 let message = chat:: send_text_msg ( & alice, chat, "Hello World" . to_owned ( ) ) . await ?;
450449
451450 alice. evtracker . clear_events ( ) ;
@@ -503,7 +502,7 @@ mod test_chatlist_events {
503502 async fn test_update_after_ephemeral_messages ( ) -> Result < ( ) > {
504503 let mut tcm = TestContextManager :: new ( ) ;
505504 let alice = tcm. alice ( ) . await ;
506- let chat = create_group_chat ( & alice, "My Group" ) . await ?;
505+ let chat = create_group ( & alice, "My Group" ) . await ?;
507506 chat. set_ephemeral_timer ( & alice, crate :: ephemeral:: Timer :: Enabled { duration : 60 } )
508507 . await ?;
509508 alice
@@ -547,7 +546,7 @@ First thread."#;
547546 let alice = tcm. alice ( ) . await ;
548547 let bob = tcm. bob ( ) . await ;
549548
550- let alice_chatid = chat:: create_group_chat ( & alice. ctx , "the chat" ) . await ?;
549+ let alice_chatid = chat:: create_group ( & alice. ctx , "the chat" ) . await ?;
551550
552551 // Step 1: Generate QR-code, secure-join implied by chatid
553552 let qr = get_securejoin_qr ( & alice. ctx , Some ( alice_chatid) ) . await ?;
@@ -594,7 +593,7 @@ First thread."#;
594593 async fn test_resend_message ( ) -> Result < ( ) > {
595594 let mut tcm = TestContextManager :: new ( ) ;
596595 let alice = tcm. alice ( ) . await ;
597- let chat = create_group_chat ( & alice, "My Group" ) . await ?;
596+ let chat = create_group ( & alice, "My Group" ) . await ?;
598597
599598 let msg_id = chat:: send_text_msg ( & alice, chat, "Hello" . to_owned ( ) ) . await ?;
600599 let _ = alice. pop_sent_msg ( ) . await ;
@@ -614,7 +613,7 @@ First thread."#;
614613 async fn test_reaction ( ) -> Result < ( ) > {
615614 let mut tcm = TestContextManager :: new ( ) ;
616615 let alice = tcm. alice ( ) . await ;
617- let chat = create_group_chat ( & alice, "My Group" ) . await ?;
616+ let chat = create_group ( & alice, "My Group" ) . await ?;
618617 let msg_id = chat:: send_text_msg ( & alice, chat, "Hello" . to_owned ( ) ) . await ?;
619618 let _ = alice. pop_sent_msg ( ) . await ;
620619
0 commit comments