From f21b5af5689591ac5fc5bbaf979567fcabd490f6 Mon Sep 17 00:00:00 2001 From: Alexander Bondarenko <486682+dpwiz@users.noreply.github.com> Date: Wed, 29 May 2024 22:00:47 +0300 Subject: [PATCH] more races --- tests/ChatTests/Direct.hs | 4 ++-- tests/ChatTests/Groups.hs | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/ChatTests/Direct.hs b/tests/ChatTests/Direct.hs index 24281ae830..5dd8d7f250 100644 --- a/tests/ChatTests/Direct.hs +++ b/tests/ChatTests/Direct.hs @@ -1448,6 +1448,7 @@ testUsersSubscribeAfterRestart :: HasCallStack => FilePath -> IO () testUsersSubscribeAfterRestart tmp = do withNewTestChat tmp "bob" bobProfile $ \bob -> do withNewTestChat tmp "alice" aliceProfile $ \alice -> do + threadDelay 100000 connectUsers alice bob alice <##> bob @@ -1458,8 +1459,7 @@ testUsersSubscribeAfterRestart tmp = do withTestChat tmp "alice" $ \alice -> do -- second user is active - alice <## "1 contacts connected (use /cs for the list)" - alice <## "[user: alice] 1 contacts connected (use /cs for the list)" + alice <### ["1 contacts connected (use /cs for the list)", "[user: alice] 1 contacts connected (use /cs for the list)"] -- second user receives message alice <##> bob diff --git a/tests/ChatTests/Groups.hs b/tests/ChatTests/Groups.hs index 838b6c65dc..58cb3673d9 100644 --- a/tests/ChatTests/Groups.hs +++ b/tests/ChatTests/Groups.hs @@ -3191,6 +3191,7 @@ testPlanGroupLinkNoContactKnown = testPlanGroupLinkNoContactConnecting :: HasCallStack => FilePath -> IO () testPlanGroupLinkNoContactConnecting tmp = do gLink <- withNewTestChat tmp "alice" aliceProfile $ \alice -> do + threadDelay 100000 alice ##> "/g team" alice <## "group #team is created" alice <## "to add members use /a team or /create link #team"