Commit 4be7a8b7 authored by take_cheeze's avatar take_cheeze

add root fiber resume test to know double resume checking is working

parent 19c4bf6f
......@@ -105,3 +105,13 @@ assert('Recursive resume of Fiber') do
assert_false f2.alive?
assert_false f3.alive?
end
assert('Root fiber resume') do
root = Fiber.current
assert_raise(RuntimeError) { root.resume }
f = Fiber.new {
assert_raise(RuntimeError) { root.resume }
}
f.resume
assert_false f.alive?
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment