diff options
author | aycabta <aycabta@gmail.com> | 2021-12-24 20:55:59 +0900 |
---|---|---|
committer | aycabta <aycabta@gmail.com> | 2021-12-24 20:55:59 +0900 |
commit | 0fbf1f193a863a2aa2d69621b530668a268e539a (patch) | |
tree | 5fec664aa1899afcf4a2c9600317d9f4c85f5e46 | |
parent | 5138ef3875ca3ee7fc94cea536cb4f9cb50ea3fd (diff) | |
download | ruby-0fbf1f193a863a2aa2d69621b530668a268e539a.tar.gz |
Add logging about timeout
-rw-r--r-- | test/readline/test_readline.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/readline/test_readline.rb b/test/readline/test_readline.rb index 2f671d4e6f..ad6be82f99 100644 --- a/test/readline/test_readline.rb +++ b/test/readline/test_readline.rb @@ -568,6 +568,7 @@ module BasetestReadline end rescue Timeout::Error => e Process.kill(:KILL, pid) + log << "\nKilled by timeout" assert false, "Timed out to handle SIGINT!\nLog: #{log}\nBacktrace:\n#{e.full_message(highlight: false)}\n----" ensure status = nil @@ -576,6 +577,7 @@ module BasetestReadline status = Process.wait2(pid).last end rescue Timeout::Error => e + log << "\nKilled by timeout to wait2" Process.kill(:KILL, pid) assert false, "Timed out to wait for terminating a process in a test of SIGINT!\nLog: #{log}\nBacktrace:\n#{e.full_message(highlight: false)}\n----" end |