diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/ruby/test_thread.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/ruby/test_thread.rb b/test/ruby/test_thread.rb index 95f2c89db4..fb2efec552 100644 --- a/test/ruby/test_thread.rb +++ b/test/ruby/test_thread.rb @@ -881,4 +881,12 @@ class TestThreadGroup < Test::Unit::TestCase Thread.current.join end end + + def test_thread_join_main_thread + assert_raises(ThreadError) do + Thread.new(Thread.current) {|t| + t.join + }.join + end + end end |