Don't force fixtures rebuild on each rspec run

Main purpose of fixtures for us is to speed up test runs. Rebuilding
fixtures each run makes them pointless. They will be rebuilt automatically
if some of "files_to_check" are changed, so we're protected from the case
when fixtures are outdated and don't load properly.
This commit is contained in:
cmrd Senya 2017-09-24 13:00:40 +03:00 committed by Benjamin Neff
parent 9ee9dbe969
commit 265a7ee253
No known key found for this signature in database
GPG key ID: 971464C3F1A90194

View file

@ -82,9 +82,6 @@ def client_assertion_with_nonexistent_client_id_path
"client_assertion_with_nonexistent_client_id.txt")
end
# Force fixture rebuild
FileUtils.rm_f(Rails.root.join("tmp", "fixture_builder.yml"))
# Requires supporting files with custom matchers and macros, etc,
# in ./support/ and its subdirectories.
fixture_builder_file = "#{File.dirname(__FILE__)}/support/fixture_builder.rb"
@ -93,6 +90,9 @@ support_files.each {|f| require f }
require fixture_builder_file
RSpec.configure do |config|
config.fixture_path = Rails.root.join("spec", "fixtures")
config.global_fixtures = :all
config.include Devise::Test::ControllerHelpers, type: :controller
config.include Devise::Test::IntegrationHelpers, type: :request
config.mock_with :rspec