From e3488fcee1a5106a670d5f966649556b8ec4c9d0 Mon Sep 17 00:00:00 2001 From: naruse Date: Wed, 14 Aug 2013 10:16:33 +0000 Subject: get detailed ps data to debug add -L/-H/-M to get thread info git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42553 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/ruby/test_notimp.rb | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'test/ruby/test_notimp.rb') diff --git a/test/ruby/test_notimp.rb b/test/ruby/test_notimp.rb index d16ad5155b..10affd6c81 100644 --- a/test/ruby/test_notimp.rb +++ b/test/ruby/test_notimp.rb @@ -30,7 +30,16 @@ class TestNotImplement < Test::Unit::TestCase pid = nil } rescue Timeout::Error - ps = `ps -l #{pid}` + case RUBY_PLATFORM + when /linux/ # assume Linux Distribution uses procps + ps = `ps -eLf #{pid}` + when /freebsd/ + ps = `ps -lH #{pid}` + when /darwin/ + ps = `ps -lM #{pid}` + else + ps = `ps -l #{pid}` + end Process.kill(:KILL, pid) Process.wait pid assert_equal nil, pid, ps -- cgit v1.2.3