Skip to content

A platform for community discussion. Free, open, simple.

DEV: Don't join on a thread forever.

Guo Xiang Tan79ba418edd89
diff --git a/spec/components/active_record/connection_adapters/postgresql_fallback_adapter_spec.rb b/spec/components/active_record/connection_adapters/postgresql_fallback_adapter_spec.rb
index 19e36438eaf..a5085b6c813 100644
--- a/spec/components/active_record/connection_adapters/postgresql_fallback_adapter_spec.rb
+++ b/spec/components/active_record/connection_adapters/postgresql_fallback_adapter_spec.rb
@@ -42,7 +42,7 @@ describe ActiveRecord::ConnectionHandling do
ActiveRecord::Base.unstub(:postgresql_connection)
ActiveRecord::Base.establish_connection
- (Thread.list - @threads).each(&:join)
+ (Thread.list - @threads).each { |thread| thread.join(5) }
end
describe "#postgresql_fallback_connection" do