* test/lib/minitest/unit.rb: Sort leaked threads and tempfiles.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46104 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
c3abc41532
commit
36c9605a6e
@ -1,3 +1,7 @@
|
|||||||
|
Sun May 25 12:32:42 2014 Tanaka Akira <akr@fsij.org>
|
||||||
|
|
||||||
|
* test/lib/minitest/unit.rb: Sort leaked threads and tempfiles.
|
||||||
|
|
||||||
Sun May 25 12:15:30 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Sun May 25 12:15:30 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* signal.c (check_stack_overflow): fix condition to use ucontext
|
* signal.c (check_stack_overflow): fix condition to use ucontext
|
||||||
|
@ -964,15 +964,18 @@ module MiniTest
|
|||||||
live2 = live_thread_and_tempfile
|
live2 = live_thread_and_tempfile
|
||||||
thread_finished = live1[0] - live2[0]
|
thread_finished = live1[0] - live2[0]
|
||||||
if !thread_finished.empty?
|
if !thread_finished.empty?
|
||||||
puts "Finished threads: #{inst.class}\##{inst.__name__}:#{thread_finished.map {|t| ' ' + t.inspect }.join}"
|
list = thread_finished.map {|t| ' ' + t.inspect }.sort.join
|
||||||
|
puts "Finished threads: #{inst.class}\##{inst.__name__}:#{list}"
|
||||||
end
|
end
|
||||||
thread_retained = live2[0] - live1[0]
|
thread_retained = live2[0] - live1[0]
|
||||||
if !thread_retained.empty?
|
if !thread_retained.empty?
|
||||||
puts "Leaked threads: #{inst.class}\##{inst.__name__}:#{thread_retained.map {|t| ' ' + t.inspect }.join}"
|
list = thread_retained.map {|t| ' ' + t.inspect }.sort.join
|
||||||
|
puts "Leaked threads: #{inst.class}\##{inst.__name__}:#{list}"
|
||||||
end
|
end
|
||||||
tempfile_retained = live2[1] - live1[1]
|
tempfile_retained = live2[1] - live1[1]
|
||||||
if !tempfile_retained.empty?
|
if !tempfile_retained.empty?
|
||||||
puts "Leaked tempfiles: #{inst.class}\##{inst.__name__}:#{tempfile_retained.map {|t| ' ' + t.inspect }.join}"
|
list = tempfile_retained.map {|t| ' ' + t.inspect }.sort.join
|
||||||
|
puts "Leaked tempfiles: #{inst.class}\##{inst.__name__}:#{list}"
|
||||||
tempfile_retained.each {|t| t.unlink }
|
tempfile_retained.each {|t| t.unlink }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user