Sha256: 7b212d0d964063d0e202b9e02c4bf5c3b1119b00287fba1aeb3d34d2d6669838

Contents?: true

Size: 1.03 KB

Versions: 4

Compression:

Stored size: 1.03 KB

Contents

ENV["RAILS_ENV"] = "test"
require File.join(File.dirname(__FILE__), 'rails_app', 'config', 'environment')

require 'test_help'
require 'webrat'

Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}

ActionMailer::Base.delivery_method = :test
ActionMailer::Base.perform_deliveries = true
ActionMailer::Base.default_url_options[:host] = 'test.com'

ActiveRecord::Migration.verbose = false
ActiveRecord::Base.logger = Logger.new(nil)
ActiveRecord::Base.establish_connection(:adapter => "sqlite3", :database => ":memory:")

ActiveRecord::Schema.define(:version => 1) do
  [:users, :admins, :accounts].each do |table|
    create_table table do |t|
      t.authenticatable :null => table == :admins

      if table != :admin
        t.string :username
        t.confirmable
        t.recoverable
        t.rememberable
      end

      t.timestamps
    end
  end
end

Webrat.configure do |config|
  config.mode = :rails
end

class ActiveSupport::TestCase
  self.use_transactional_fixtures = true
  self.use_instantiated_fixtures  = false
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
devise-0.6.0 test/test_helper.rb
devise-0.5.6 test/test_helper.rb
devise-0.5.5 test/test_helper.rb
devise-0.5.4 test/test_helper.rb