Suppress expected exceptions by report_on_exception
= false
This suppresses `Timeout::Error` exceptions. Ref: https://travis-ci.org/rails/rails/jobs/334622442#L1089-L1110
This commit is contained in:
parent
133dc3b6d0
commit
bee764965e
@ -2,6 +2,8 @@
|
||||
|
||||
module ConnectionPoolBehavior
|
||||
def test_connection_pool
|
||||
Thread.report_on_exception, original_report_on_exception = false, Thread.report_on_exception if Thread.respond_to?(:report_on_exception)
|
||||
|
||||
emulating_latency do
|
||||
begin
|
||||
cache = ActiveSupport::Cache.lookup_store(store, pool_size: 2, pool_timeout: 1)
|
||||
@ -24,6 +26,8 @@ def test_connection_pool
|
||||
threads.each(&:kill)
|
||||
end
|
||||
end
|
||||
ensure
|
||||
Thread.report_on_exception = original_report_on_exception if Thread.respond_to?(:report_on_exception)
|
||||
end
|
||||
|
||||
def test_no_connection_pool
|
||||
|
Loading…
Reference in New Issue
Block a user