Sha256: b11c108c11cd68c75cd00057572df1398ea0bc936e399c7da156103e7882f4d6

Contents?: true

Size: 1.09 KB

Versions: 18

Compression:

Stored size: 1.09 KB

Contents

ENV["RAILS_ENV"] ||= 'test'

require 'simplecov'
require 'coveralls'
require 'factory_girl_rails'

#FactoryGirl.definition_file_paths << File.expand_path("../../../pages/spec")

SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
    SimpleCov::Formatter::HTMLFormatter,
    Coveralls::SimpleCov::Formatter
]

SimpleCov.start 'rails'

ENGINE_RAILS_ROOT = File.join(File.dirname(__FILE__), '../') unless defined?(ENGINE_RAILS_ROOT)

require File.expand_path("../dummy/config/environment", __FILE__)

require 'rspec/rails'
require 'capybara/rails'
require 'capybara/rspec'
require 'database_cleaner'

include Warden::Test::Helpers
Warden.test_mode!

Rails.backtrace_cleaner.remove_silencers!

Dir[File.join(ENGINE_RAILS_ROOT, 'spec/support/**/*.rb')].each {|f| require f}

RSpec.configure do |config|
  config.use_transactional_fixtures = false

  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

  config.mock_with :rspec
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
constructor-cms-1.0.0beta2 spec/spec_helper.rb
constructor-cms-1.0.0beta1 spec/spec_helper.rb
constructor-cms-0.9.1 spec/spec_helper.rb
constructor-cms-0.9.0 spec/spec_helper.rb
constructor-cms-0.8.19 spec/spec_helper.rb
constructor-cms-0.8.18 spec/spec_helper.rb
constructor-cms-0.8.17 spec/spec_helper.rb
constructor-cms-0.8.16 spec/spec_helper.rb
constructor-cms-0.8.15 spec/spec_helper.rb
constructor-cms-0.8.14 spec/spec_helper.rb
constructor-cms-0.8.13 spec/spec_helper.rb
constructor-cms-0.8.12 spec/spec_helper.rb
constructor-cms-0.8.11 spec/spec_helper.rb
constructor-cms-0.8.10 spec/spec_helper.rb
constructor-cms-0.8.8 spec/spec_helper.rb
constructor-cms-0.8.7 spec/spec_helper.rb
constructor-cms-0.8.6 spec/spec_helper.rb
constructor-cms-0.8.5 spec/spec_helper.rb