spec/helper.rb in remember_me-0.1.1 vs spec/helper.rb in remember_me-1.0.0
- old
+ new
@@ -9,29 +9,31 @@
SimpleCov.start
end
require 'rails'
require 'action_controller'
+require 'action_view'
require 'active_support/concern'
-require 'active_record'
require 'mongoid'
require 'remember_me'
require 'rspec'
require 'rspec/rails'
+require 'securerandom'
RSpec.configure do |config|
config.mock_with :rspec
+ config.infer_base_class_for_anonymous_controllers = true
end
module Example
class Application < Rails::Application
end
end
-Example::Application.routes.draw do
- post 'signin', to: 'sessions#create'
- get 'signout', to: 'sessions#destroy'
-end
+# for secret_key_base
+Example::Application.config.secret_key_base = SecureRandom.hex(64)
+
+Example::Application.config.session_options = {}
class User
include Mongoid::Document
include RememberMe::Model
def save(arg = {})