Permalink
Browse files

Travis: try reconnect instead of establish connection.

  • Loading branch information...
1 parent c4bcb9f commit 8ac8455f18b2a1b1a48a1e7079d16343b01abbbc @assaf assaf committed Aug 2, 2011
Showing with 1 addition and 2 deletions.
  1. +1 −1 lib/vanity/frameworks/rails.rb
  2. +0 −1 test/test_helper.rb
@@ -324,7 +324,7 @@ class Plugin < Rails::Railtie # :nodoc:
PhusionPassenger.on_event(:starting_worker_process) do |forked|
if forked
begin
- Vanity.playground.establish_connection if Vanity.playground.collecting?
+ Vanity.playground.reconnect! if Vanity.playground.collecting?
rescue Exception=>ex
Rails.logger.error "Error reconnecting: #{ex.to_s}"
end
View
@@ -107,7 +107,6 @@ def teardown
ActiveRecord::Base.logger = $logger
-ActiveRecord::Base.verification_timeout = 10
ActiveRecord::Base.establish_connection :adapter=>"mysql", :database=>"vanity_test"
if ENV["DB"] == "mysql" || ENV["DB"] == "postgres"

0 comments on commit 8ac8455

Please sign in to comment.