summaryrefslogtreecommitdiff
path: root/test/lib/minitest
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-05-25 16:16:38 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-05-25 16:16:38 +0000
commitc8660d896698e31a62ad9c149213e315a70a1035 (patch)
treeeb60c18a7c3cd7b4afa227d44da081cbf55c61a5 /test/lib/minitest
parentfc85af7bc49b81f81077ae060e47bafe384c9079 (diff)
Show leaked threads line-by-line.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46122 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/lib/minitest')
-rw-r--r--test/lib/minitest/unit.rb8
1 files changed, 5 insertions, 3 deletions
diff --git a/test/lib/minitest/unit.rb b/test/lib/minitest/unit.rb
index 27c71b1..a27926b 100644
--- a/test/lib/minitest/unit.rb
+++ b/test/lib/minitest/unit.rb
@@ -974,8 +974,10 @@ module MiniTest
end
thread_retained = live2 - live1
if !thread_retained.empty?
- list = thread_retained.map {|t| ' ' + t.inspect }.sort.join
- puts "Leaked threads: #{inst.class}\##{inst.__name__}:#{list}"
+ list = thread_retained.map {|t| t.inspect }.sort
+ list.each {|str|
+ puts "Leaked thread: #{inst.class}\##{inst.__name__}: #{str}"
+ }
end
live2
end
@@ -998,7 +1000,7 @@ module MiniTest
end
tempfile_retained = live2 - live1
if !tempfile_retained.empty?
- list = tempfile_retained.map {|t| ' ' + t.inspect }.sort
+ list = tempfile_retained.map {|t| t.inspect }.sort
list.each {|str|
puts "Leaked tempfile: #{name}: #{str}"
}