thoughtbot--shoulda-matchers/spec/spec_helper.rb

27 lines
694 B
Ruby
Raw Normal View History

require File.expand_path('../support/test_application', __FILE__)
$test_app = TestApplication.new
$test_app.create
$test_app.load
ENV['BUNDLE_GEMFILE'] ||= app.gemfile_path
ENV['RAILS_ENV'] = 'test'
2012-03-24 00:00:09 +00:00
require 'bourne'
2012-03-24 01:00:36 +00:00
require 'shoulda-matchers'
require 'rspec/rails'
PROJECT_ROOT = File.expand_path('../..', __FILE__)
$LOAD_PATH << File.join(PROJECT_ROOT, 'lib')
Dir[ File.join(PROJECT_ROOT, 'spec/support/**/*.rb') ].each { |file| require file }
RSpec.configure do |config|
2014-01-17 22:01:43 +00:00
config.expect_with :rspec do |c|
c.syntax = :expect
end
config.mock_with :mocha
2010-12-15 22:34:19 +00:00
config.include Shoulda::Matchers::ActionController,
example_group: { file_path: /action_controller/ }
end