From 7c893c8d6bbd1c84b3081d95aac3f8d69f8c20fb Mon Sep 17 00:00:00 2001 From: Yusuke Endoh Date: Thu, 7 Nov 2024 10:18:48 +0900 Subject: [PATCH] Loosen the criteria for timing checks of Kernel#sleep The test was too flaky --- spec/ruby/core/kernel/sleep_spec.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/ruby/core/kernel/sleep_spec.rb b/spec/ruby/core/kernel/sleep_spec.rb index 1de52a707f..fd8551fe10 100644 --- a/spec/ruby/core/kernel/sleep_spec.rb +++ b/spec/ruby/core/kernel/sleep_spec.rb @@ -61,7 +61,7 @@ describe "Kernel#sleep" do actual_duration = end_time - start_time (actual_duration > 0.01).should == true # 100 * 0.0001 => 0.01 - (actual_duration < 0.03).should == true + (actual_duration < 1).should == true end end