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

Merge pull request #13480 from kuldeepaggarwal/f-removed-depricated-config

using symbol instead of string in establish_connection
This commit is contained in:
José Valim 2013-12-25 04:48:56 -08:00
commit 84d47d073e
2 changed files with 2 additions and 2 deletions

View file

@ -92,7 +92,7 @@ module ActiveRecord
)
end
ensure
ActiveRecord::Base.establish_connection 'arunit'
ActiveRecord::Base.establish_connection :arunit
end
end
end

View file

@ -153,7 +153,7 @@ module ApplicationTests
`rails generate model book title:string;
bundle exec rake db:migrate db:structure:dump db:test:load_structure`
ActiveRecord::Base.configurations = Rails.application.config.database_configuration
ActiveRecord::Base.establish_connection 'test'
ActiveRecord::Base.establish_connection :test
require "#{app_path}/app/models/book"
#if structure is not loaded correctly, exception would be raised
assert Book.count, 0