Sha256: c3524f17a2cca6449d1e5f8b2e7af7680e43865c5fae63b9e8cd28ab38083bb7

Contents?: true

Size: 1.08 KB

Versions: 3

Compression:

Stored size: 1.08 KB

Contents

ENV["RAILS_ENV"] ||= 'test'
require File.expand_path("../dummy/config/environment", __FILE__)
require 'rspec/rails'
require 'devise/test_helpers'


ENGINE_RAILS_ROOT=File.join(File.dirname(__FILE__), '../')
# Requires supporting ruby files with custom matchers and macros, etc,
# in spec/support/ and its subdirectories.
Dir[("#{ENGINE_RAILS_ROOT}/spec/support/**/*.rb")].each {|f| require f}

RSpec.configure do |config|
  config.treat_symbols_as_metadata_keys_with_true_values = true
  config.run_all_when_everything_filtered = true
  config.filter_run :focus

  config.mock_with :rspec
  config.include FactoryGirl::Syntax::Methods
  config.include Devise::TestHelpers, :type => :controller

  config.before(:suite) do
    DatabaseCleaner.strategy = :transaction
    DatabaseCleaner.clean_with(:truncation)
  end

  config.before(:each) do
    DatabaseCleaner.start
  end

  config.after(:each) do
    DatabaseCleaner.clean
  end
end

["../../db/migrate", "../dummy/db/migrate"].each do |migration_path|
  ActiveRecord::Migrator.migrate(File.expand_path(migration_path, __FILE__))  
end

require 'factories'

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
devise_oauth-2.0.3 spec/spec_helper.rb
devise_oauth-2.0.2 spec/spec_helper.rb
devise_oauth-2.0.1 spec/spec_helper.rb