summaryrefslogtreecommitdiff
path: root/test/lib
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-06-15 01:51:49 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-06-15 01:51:49 +0000
commit5c5b2505a1104cfbb1eb13577245f2eb4f66d47f (patch)
tree2e184d45ad5c7f52992360e247acb373046c5d0e /test/lib
parent1ab22a5672eeec31976dc2a34f8531aa00268663 (diff)
envutil.rb: no signal description iff possible
* test/lib/envutil.rb (FailDesc): show signal description only if it is available, or nothing if not killed by a signal. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50905 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/lib')
-rw-r--r--test/lib/envutil.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/lib/envutil.rb b/test/lib/envutil.rb
index cbb8558..3b3c633 100644
--- a/test/lib/envutil.rb
+++ b/test/lib/envutil.rb
@@ -329,7 +329,8 @@ module Test
if message and !message.empty?
full_message << message << "\n"
end
- full_message << "pid #{pid} killed by #{sigdesc}"
+ full_message << "pid #{pid}"
+ full_message << " killed by #{sigdesc}" if sigdesc
if out and !out.empty?
full_message << "\n#{out.gsub(/^/, '| ')}"
full_message << "\n" if /\n\z/ !~ full_message