summaryrefslogtreecommitdiff
path: root/test/test_timeout.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/test_timeout.rb')
-rw-r--r--test/test_timeout.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/test_timeout.rb b/test/test_timeout.rb
index e4eba7f..fcaf715 100644
--- a/test/test_timeout.rb
+++ b/test/test_timeout.rb
@@ -60,6 +60,11 @@ class TestTimeout < Test::Unit::TestCase
assert_nothing_raised(ArgumentError, bug9354) do
assert_equal(:ok, timeout(100, err) {:ok})
end
+ assert_raise_with_message(err, /execution expired/) do
+ timeout 0.01, err do
+ sleep 3
+ end
+ end
end
def test_exit_exception