Project

General

Profile

« Previous | Next » 

Revision 5b391a40

Added by Joseph Magen almost 10 years ago

fixes #6112 - log/test.log disappears when running under spork

View differences:

test/test_helper.rb
end
end
# Remove previous test log to speed tests up
test_log = File.expand_path('../../log/test.log', __FILE__)
FileUtils.rm(test_log) if File.exists?(test_log)
Spork.prefork do
# Loading more in this block will cause your tests to run faster. However,
# if you change any configuration or code from libraries loaded here, you'll
# need to restart spork for it take effect.
# Remove previous test log to speed tests up
test_log = File.expand_path('../../log/test.log', __FILE__)
FileUtils.rm(test_log) if File.exists?(test_log)
ENV["RAILS_ENV"] = "test"
require File.expand_path('../../config/environment', __FILE__)
require 'rails/test_help'

Also available in: Unified diff