diff options
Diffstat (limited to 'activerecord/test/connections/native_mysql')
-rw-r--r-- | activerecord/test/connections/native_mysql/connection.rb | 29 |
1 files changed, 15 insertions, 14 deletions
diff --git a/activerecord/test/connections/native_mysql/connection.rb b/activerecord/test/connections/native_mysql/connection.rb index b665a6b449..9a91a75cac 100644 --- a/activerecord/test/connections/native_mysql/connection.rb +++ b/activerecord/test/connections/native_mysql/connection.rb @@ -4,18 +4,19 @@ require 'logger' ActiveRecord::Base.logger = Logger.new("debug.log") -db1 = 'activerecord_unittest' -db2 = 'activerecord_unittest2' +ActiveRecord::Base.configurations = { + 'arunit' => { + :adapter => 'mysql', + :username => 'rails', + :encoding => 'utf8', + :database => 'activerecord_unittest', + }, + 'arunit2' => { + :adapter => 'mysql', + :username => 'rails', + :database => 'activerecord_unittest2' + } +} -ActiveRecord::Base.establish_connection( - :adapter => "mysql", - :username => "rails", - :encoding => "utf8", - :database => db1 -) - -Course.establish_connection( - :adapter => "mysql", - :username => "rails", - :database => db2 -) +ActiveRecord::Base.establish_connection 'arunit' +Course.establish_connection 'arunit2' |