1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* lib/timeout.rb (Timeout#timeout): propagate errors to the

caller.  [ruby-dev:41010]'


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27397 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2010-04-19 09:58:09 +00:00
parent 75ef9e79d6
commit 312d5bf7f2

View file

@ -23,4 +23,10 @@ class TestTimeout < Test::Unit::TestCase
end
assert !@flag, "[ruby-dev:38319]"
end
def test_cannot_convert_into_time_interval
bug3168 = '[ruby-dev:41010]'
def (n = Object.new).zero?; false; end
assert_raise(TypeError, bug3168) {Timeout.timeout(n) { sleep 0.1 }}
end
end