back out r6078.

NoMethodError: undefined method `mkdir_p' for #<Pathname:0x7f56f9deb3c0>

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@6080 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Toshi MARUYAMA 2011-06-16 03:53:07 +00:00
parent 2797b1f388
commit 153028f14a
1 changed files with 3 additions and 2 deletions

View File

@ -78,8 +78,9 @@ class ActiveSupport::TestCase
# Use a temporary directory for attachment related tests
def set_tmp_attachments_directory
Rails.root.join('tmp/test/attachments').mkdir_p
Attachment.storage_path = "#{Rails.root}/tmp/test/attachments"
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
def with_settings(options, &block)