diff options
author | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2023-03-22 17:58:49 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2023-03-22 18:53:12 +0900 |
commit | 09bda4ceb592801d1729a2e7b4aea164dc855f6d (patch) | |
tree | c203c86eee2999a24193789e52682d643b4afe1e /tool/lib/core_assertions.rb | |
parent | 6cc8eb4daadbbc0cf3b6be4bed48f7d5a476f557 (diff) | |
download | ruby-09bda4ceb592801d1729a2e7b4aea164dc855f6d.tar.gz |
core_assertions.rb: Refine `assert_linear_performance`
* Calculate each timeout from the ratio of each factor to the first
factor.
Diffstat (limited to 'tool/lib/core_assertions.rb')
-rw-r--r-- | tool/lib/core_assertions.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tool/lib/core_assertions.rb b/tool/lib/core_assertions.rb index d9d633a0ac..1662024e7d 100644 --- a/tool/lib/core_assertions.rb +++ b/tool/lib/core_assertions.rb @@ -760,7 +760,7 @@ eom seq.each do |i| next if i == first - t = (tmax * i).to_f + t = tmax * i.fdiv(first) *arg = pre.call(i) message = "[#{i}]: in #{t}s" Timeout.timeout(t, nil, message) do |