diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2014-03-17 17:37:05 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2014-03-17 17:37:05 -0700 |
commit | 34e54fa0542ebb3403932ab785239119e449dc3c (patch) | |
tree | e02a8141c45f7ed1f65fdccba4e1d2f1dd4a7db6 /activerecord/test | |
parent | 4db4f909174420904d48a9712e337b697d372ac3 (diff) | |
download | rails-34e54fa0542ebb3403932ab785239119e449dc3c.tar.gz rails-34e54fa0542ebb3403932ab785239119e449dc3c.tar.bz2 rails-34e54fa0542ebb3403932ab785239119e449dc3c.zip |
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.
Diffstat (limited to 'activerecord/test')
-rw-r--r-- | activerecord/test/cases/connection_pool_test.rb | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/activerecord/test/cases/connection_pool_test.rb b/activerecord/test/cases/connection_pool_test.rb index c0d5e3707c..8d15a76735 100644 --- a/activerecord/test/cases/connection_pool_test.rb +++ b/activerecord/test/cases/connection_pool_test.rb @@ -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 |