This repository has been archived by the owner on May 9, 2018. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
15 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,21 @@ | ||
require 'spork' | ||
# This file is copied to spec/ when you run 'rails generate rspec:install' | ||
ENV["RAILS_ENV"] ||= 'test' | ||
require File.expand_path("../../config/environment", __FILE__) | ||
require 'rspec/rails' | ||
|
||
Spork.prefork do | ||
# This file is copied to spec/ when you run 'rails generate rspec:install' | ||
ENV["RAILS_ENV"] ||= 'test' | ||
require File.expand_path("../../config/environment", __FILE__) | ||
require 'rspec/rails' | ||
FakeWeb.allow_net_connect = false | ||
|
||
FakeWeb.allow_net_connect = false | ||
end | ||
|
||
Spork.each_run do | ||
# Requires supporting ruby files with custom matchers and macros, etc, | ||
# in spec/support/ and its subdirectories. | ||
Dir[Rails.root.join("spec/support/**/*.rb")].each {|f| require f} | ||
# Requires supporting ruby files with custom matchers and macros, etc, | ||
# in spec/support/ and its subdirectories. | ||
Dir[Rails.root.join("spec/support/**/*.rb")].each {|f| require f} | ||
|
||
RSpec.configure do |config| | ||
config.mock_with :mocha | ||
config.use_transactional_fixtures = true | ||
RSpec.configure do |config| | ||
config.mock_with :mocha | ||
config.use_transactional_fixtures = true | ||
|
||
config.include(FileFixture) | ||
config.include(ControllerHelper, :type => :controller) | ||
config.include(LoginHelper, :type => :controller) | ||
config.include(FileFixture) | ||
config.include(ControllerHelper, :type => :controller) | ||
config.include(LoginHelper, :type => :controller) | ||
|
||
config.after(:each) { User.delete_all } | ||
end | ||
config.after(:each) { User.delete_all } | ||
end |