Sha256: 936b44ff00faeb6ec6061e3526555ae4fd7768bbff423d8f0cbee907787e4120
Contents?: true
Size: 1.19 KB
Versions: 5
Compression:
Stored size: 1.19 KB
Contents
require 'rubygems' gem 'rspec' gem 'activerecord' $:.unshift(File.dirname(__FILE__) + '/../lib') $:.unshift(File.dirname(__FILE__) + '/fixtures') require 'active_record' require 'active_record/fixtures' gem 'pg' begin gem 'arel' rescue Gem::LoadError require 'fake_arel' class ActiveRecord::Base named_scope :joins, lambda {|*join| {:joins => join } if join[0]} end end require 'cancan' require 'cancan/matchers' require 'ar_pg_array' ActiveRecord::Base.establish_connection( :adapter => 'postgresql', :database => 'postgres', :encoding => 'utf8' ) ActiveRecord::Base.connection.create_database('test_pg_array', :encoding=>'utf8') rescue nil ActiveRecord::Base.establish_connection( :adapter => 'postgresql', :database => 'test_pg_array', :encoding => 'utf8' ) ActiveRecord::Base.logger = Logger.new(STDOUT) #if $0 == 'irb' require 'tag' require 'item' require 'bulk' require 'unrelated' ActiveRecord::Base.silence do ActiveRecord::Migration.verbose = false # load schema load File.join('spec/fixtures/schema.rb') # load fixtures Fixtures = ActiveRecord::Fixtures unless defined?(Fixtures) Fixtures.create_fixtures("spec/fixtures", ActiveRecord::Base.connection.tables) end
Version data entries
5 entries across 5 versions & 1 rubygems