~michaelforrest/use-case-mapper/trunk

« back to all changes in this revision

Viewing changes to vendor/rails/activerecord/test/connections/jdbc_jdbcmysql/connection.rb

  • Committer: Michael Forrest
  • Date: 2010-10-15 16:28:50 UTC
  • Revision ID: michael.forrest@canonical.com-20101015162850-tj2vchanv0kr0dun
refrozeĀ gems

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
print "Using MySQL via JRuby, activerecord-jdbc-adapter and activerecord-jdbcmysql-adapter\n"
 
2
require_dependency 'models/course'
 
3
require 'logger'
 
4
 
 
5
ActiveRecord::Base.logger = Logger.new("debug.log")
 
6
 
 
7
# GRANT ALL PRIVILEGES ON activerecord_unittest.* to 'rails'@'localhost';
 
8
# GRANT ALL PRIVILEGES ON activerecord_unittest2.* to 'rails'@'localhost';
 
9
 
 
10
ActiveRecord::Base.configurations = {
 
11
  'arunit' => {
 
12
    :adapter  => 'jdbcmysql',
 
13
    :username => 'rails',
 
14
    :encoding => 'utf8',
 
15
    :database => 'activerecord_unittest',
 
16
  },
 
17
  'arunit2' => {
 
18
    :adapter  => 'jdbcmysql',
 
19
    :username => 'rails',
 
20
    :database => 'activerecord_unittest2'
 
21
  }
 
22
}
 
23
 
 
24
ActiveRecord::Base.establish_connection 'arunit'
 
25
Course.establish_connection 'arunit2'
 
26