diff options
-rw-r--r-- | test/ruby/test_thread.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/test/ruby/test_thread.rb b/test/ruby/test_thread.rb index 369cd0a5cd..e2a181a683 100644 --- a/test/ruby/test_thread.rb +++ b/test/ruby/test_thread.rb @@ -818,8 +818,10 @@ _eom def test_main_thread_status_at_exit assert_in_out_err([], <<-'INPUT', ["false false aborting"], []) +q = Queue.new Thread.new(Thread.current) {|mth| begin + q.push nil mth.run Thead.pass until mth.stop? p :mth_stopped # don't run if killed by rb_thread_terminate_all @@ -827,6 +829,7 @@ Thread.new(Thread.current) {|mth| puts "#{mth.alive?} #{mth.status} #{Thread.current.status}" end } +q.pop INPUT end |