Let Devise play with both Rails 3.2 and Rails 4 for now

This commit is contained in:
Carlos Antonio da Silva
2013-05-03 22:56:46 -03:00
parent 0fe0373144
commit 69f79ad446
13 changed files with 255 additions and 26 deletions

View File

@@ -4,6 +4,13 @@ DEVISE_ORM = (ENV["DEVISE_ORM"] || :active_record).to_sym
$:.unshift File.dirname(__FILE__)
puts "\n==> Devise.orm = #{DEVISE_ORM.inspect}"
module Devise
# Detection for minor differences between Rails 3.2 and 4 in tests.
def self.rails4?
Rails.version.start_with? '4'
end
end
require "rails_app/config/environment"
require "rails/test_help"
require "orm/#{DEVISE_ORM}"