From c26e029d22cb14da5bf7e8338c106d32819dd96e Mon Sep 17 00:00:00 2001 From: Vinicius Brasil Date: Thu, 13 Oct 2022 09:56:25 -0300 Subject: [PATCH] Increase flaky test timeout (#2330) --- test/support/test_utils.ex | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/support/test_utils.ex b/test/support/test_utils.ex index d2977f61d..ebd49752a 100644 --- a/test/support/test_utils.ex +++ b/test/support/test_utils.ex @@ -145,13 +145,13 @@ defmodule Plausible.TestUtils do end def eventually(expectation, wait_time_ms \\ 50, retries \\ 10) do - Enum.reduce_while(1..retries, nil, fn _i, _acc -> + Enum.reduce_while(1..retries, nil, fn attempt, _acc -> case expectation.() do {true, result} -> {:halt, result} {false, _} -> - Process.sleep(wait_time_ms) + Process.sleep(wait_time_ms * attempt) {:cont, nil} end end)