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

test should only pass if the pool.size+1 checkout fails

Previously, any of the connection checkouts could have failed, and this
test would pass.
This commit is contained in:
Aaron Patterson 2014-03-17 17:37:05 -07:00
parent 4db4f90917
commit 34e54fa054

View file

@ -89,10 +89,9 @@ module ActiveRecord
end
def test_full_pool_exception
@pool.size.times { @pool.checkout }
assert_raises(ConnectionTimeoutError) do
(@pool.size + 1).times do
@pool.checkout
end
@pool.checkout
end
end