summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2023-04-19 13:29:02 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2023-04-22 21:21:35 +0900
commit4cff7a92b8c97bb86dc1027b674a688f5182e302 (patch)
treed435c28e3b17e94de24f89385175888bae024d42 /spec
parent1702b0f438b2ac7c8b7d9c42bb5dfe23fad1df0f (diff)
downloadruby-4cff7a92b8c97bb86dc1027b674a688f5182e302.tar.gz
Fix an example of `Process.times`
Prior to commit 5806c54447439f2ba22892e4045e78dd80f96f0c, it was "at least one result with precision beyond milliseconds (with none-zero microseconds) should exist"; after this commit, "at least one result should have zero microseconds". This chance is lower than the previous condition.
Diffstat (limited to 'spec')
-rw-r--r--spec/ruby/core/process/times_spec.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/ruby/core/process/times_spec.rb b/spec/ruby/core/process/times_spec.rb
index 6142cd257c..30504ca3cf 100644
--- a/spec/ruby/core/process/times_spec.rb
+++ b/spec/ruby/core/process/times_spec.rb
@@ -30,7 +30,7 @@ describe "Process.times" do
found = (max * 100).times.find do
time = Process.times.utime
- ('%.6f' % time).end_with?('000')
+ !('%.6f' % time).end_with?('000')
end
found.should_not == nil