mirror of
https://github.com/mperham/connection_pool
synced 2023-03-27 23:22:21 -04:00
Test TimedStack#pop with an item
This commit is contained in:
parent
53ef10798e
commit
5be329da9b
1 changed files with 9 additions and 0 deletions
|
@ -24,6 +24,15 @@ class TestConnectionPoolTimedStack < Minitest::Test
|
|||
end
|
||||
|
||||
def test_pop
|
||||
object = Object.new
|
||||
@stack.push object
|
||||
|
||||
popped = @stack.pop
|
||||
|
||||
assert_same object, popped
|
||||
end
|
||||
|
||||
def test_pop_empty
|
||||
e = assert_raises Timeout::Error do
|
||||
@stack.pop 0.0000001
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue