From 15176e5176a3d3f288fb9830e08f30c8411df0bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Donatas=20Ku=C4=8Dinskas?= Date: Fri, 8 Nov 2024 23:33:42 +0200 Subject: [PATCH] Improve scaladocs of `eventually` (#1287) * Improve scaladocs of `eventually` * Update EventuallyResults.scala --- .../main/scala/org/specs2/execute/EventuallyResults.scala | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/common/shared/src/main/scala/org/specs2/execute/EventuallyResults.scala b/common/shared/src/main/scala/org/specs2/execute/EventuallyResults.scala index bb5746e991..e463283c9c 100644 --- a/common/shared/src/main/scala/org/specs2/execute/EventuallyResults.scala +++ b/common/shared/src/main/scala/org/specs2/execute/EventuallyResults.scala @@ -40,12 +40,14 @@ trait EventuallyResults: else retry(0) /** @return - * a matcher that will retry the nested matcher a given number of times + * a matcher that will retry the nested matcher a given number of times with a given duration of sleep in between */ def eventually[T: AsResult](retries: Int, sleep: Duration)(result: =>T): T = eventually[T](retries, (_: Int) => sleep)(result) - /** @return a result that is retried at least 40 times until it's ok */ + /** @return + * a matcher that will retry the nested matcher 40 times until it's ok with 100ms sleep in between + */ def eventually[T: AsResult](result: =>T): T = eventually(40, (_: Int) => 100.millis)(result)