1
0
Fork 0
mirror of https://github.com/heartcombo/devise.git synced 2022-11-09 12:18:31 -05:00
heartcombo--devise/test/test_helper.rb

22 lines
711 B
Ruby
Raw Normal View History

ENV["RAILS_ENV"] = "test"
2009-12-21 09:29:58 -05:00
DEVISE_ORM = (ENV["DEVISE_ORM"] || :active_record).to_sym
puts "\n==> Devise.orm = #{DEVISE_ORM.inspect}"
require File.expand_path('../rails_app/config/application', __FILE__)
require File.expand_path("../orm/#{DEVISE_ORM}", __FILE__)
require 'mocha'
ActionMailer::Base.delivery_method = :test
ActionMailer::Base.perform_deliveries = true
2009-10-08 10:31:51 -04:00
ActionMailer::Base.default_url_options[:host] = 'test.com'
Webrat.configure do |config|
config.mode = :rails
config.open_error_files = false
end
# Add support to load paths so we can overwrite broken webrat setup
$:.unshift File.expand_path('../support', __FILE__)
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }