diff options
Diffstat (limited to 'bootstraptest/test_exception.rb')
-rw-r--r-- | bootstraptest/test_exception.rb | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/bootstraptest/test_exception.rb b/bootstraptest/test_exception.rb index eb2c309053..bd3d02ade3 100644 --- a/bootstraptest/test_exception.rb +++ b/bootstraptest/test_exception.rb @@ -385,3 +385,20 @@ assert_match /undefined method `foo\'/, %q{ C.new.foo }, "[ruby-dev:31407]" +assert_equal 'nil', %q{ + doit = false + exc = nil + t = Thread.new { + begin + doit = true + sleep 10 + ensure + exc = $! + end + } + Thread.pass until doit + t.kill + t.join + exc.inspect +}, '[ruby-dev:32608]' + |