Sha256: f969374e8751bca01c2f25ec9435a42bcfb892f0d963fa808d357bf0e88e99f4
Contents?: true
Size: 842 Bytes
Versions: 4
Compression:
Stored size: 842 Bytes
Contents
# Set the default environment to sqlite3's in_memory database ENV['RAILS_ENV'] ||= 'in_memory' # Load the Rails environment and testing framework require "#{File.dirname(__FILE__)}/app_root/config/environment" require 'test_help' # Undo changes to RAILS_ENV silence_warnings {RAILS_ENV = ENV['RAILS_ENV']} # Run the migrations ActiveRecord::Migrator.migrate("#{Rails.root}/db/migrate") # Set default fixture loading properties ActiveSupport::TestCase.class_eval do self.use_transactional_fixtures = true self.use_instantiated_fixtures = false self.fixture_path = "#{File.dirname(__FILE__)}/fixtures" fixtures :all end # Little dummy class that returns some data for use in the views. class Monkey < Struct.new(:name) def self.find(*args) @@monkeys ||= ['Frank', 'Benny', 'Paul'].map { |name| Monkey.new name } end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
dinsley-markaby-0.0.5 | test/test_helper.rb |
dinsley-markaby-0.0.6 | test/test_helper.rb |
dinsley-markaby-0.0.7 | test/test_helper.rb |
dinsley-markaby-0.0.9 | test/test_helper.rb |