test/test_helper.rb
#Initialises ActiveRecord and loads the schema using sqlite3
Initialises ActiveRecord and loads the schema using sqlite3
Initialises ActiveRecord and loads the schema using sqlite3
def load_schema
  ActiveRecord::Base.logger = Logger.new(File.dirname(__FILE__) + "/debug.log")
  require 'sqlite3'
  ActiveRecord::Base.establish_connection({:adapter => 'sqlite3', :database => File.join(File.dirname(__FILE__), 'test.sqlite3')})
  load(File.dirname(__FILE__) + "/schema.rb")
end
def load_schema ActiveRecord :: Base . logger = Logger . new ( File . dirname ( __FILE__ ) + "/debug.log" ) require 'sqlite3' ActiveRecord :: Base . establish_connection ( { :adapter => 'sqlite3' , :database => File . join ( File . dirname ( __FILE__ ) , 'test.sqlite3' ) } ) load ( File . dirname ( __FILE__ ) + "/schema.rb" ) end
Initialises ActiveRecord and loads the schema using sqlite3
Initialises ActiveRecord and loads the schema using sqlite3