diff options
author | Nobuyoshi Nakada <[email protected]> | 2023-03-23 01:13:23 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <[email protected]> | 2023-03-23 14:49:41 +0900 |
commit | db7c38634e8e9d1017210759f99f772a88f576c4 (patch) | |
tree | 2ad98c15fbe42deda21b74189c8cb370ba396dee /tool/lib | |
parent | 0112a5b3423ddb2ddf46c4392f23f9b75128568e (diff) |
core_assertions.rb: Raise `Timeout::Error` explicitly
So that `assert_raise` inside the block works.
Diffstat (limited to 'tool/lib')
-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 52c2c6b388..1fdc0a34b8 100644 --- a/tool/lib/core_assertions.rb +++ b/tool/lib/core_assertions.rb @@ -763,7 +763,7 @@ eom t = tmax * i.fdiv(first) *arg = pre.call(i) message = "[#{i}]: in #{t}s" - Timeout.timeout(t, nil, message) do + Timeout.timeout(t, Timeout::Error, message) do st = Process.clock_gettime(Process::CLOCK_MONOTONIC) yield(*arg) assert_operator (Process.clock_gettime(Process::CLOCK_MONOTONIC) - st), :<=, t, message |