Tests: create tmp/test if it doesn't exist.

git-svn-id: http://redmine.rubyforge.org/svn/trunk@1586 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2008-06-26 14:59:03 +00:00
parent 31e3d180c0
commit ad7816cea4
1 changed files with 1 additions and 0 deletions

View File

@ -60,6 +60,7 @@ class Test::Unit::TestCase
# Use a temporary directory for attachment related tests
def set_tmp_attachments_directory
Dir.mkdir "#{RAILS_ROOT}/tmp/test" unless File.directory?("#{RAILS_ROOT}/tmp/test")
Dir.mkdir "#{RAILS_ROOT}/tmp/test/attachments" unless File.directory?("#{RAILS_ROOT}/tmp/test/attachments")
Attachment.storage_path = "#{RAILS_ROOT}/tmp/test/attachments"
end