aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport
diff options
context:
space:
mode:
authorCarlhuda <carlhuda@engineyard.com>2010-02-23 15:37:17 -0800
committerCarlhuda <carlhuda@engineyard.com>2010-02-23 15:37:17 -0800
commit3345af61fb128d0a70793b235e3cb878781d6f40 (patch)
tree13f658ed836dc7d8c15eb9486cef39f340496722 /activesupport
parentee541049fdbe5eeebcca2f3b83144a5d803345a9 (diff)
downloadrails-3345af61fb128d0a70793b235e3cb878781d6f40.tar.gz
rails-3345af61fb128d0a70793b235e3cb878781d6f40.tar.bz2
rails-3345af61fb128d0a70793b235e3cb878781d6f40.zip
Fix streaming by having it create a File object, which can be handled by Rack servers as appropriate
Diffstat (limited to 'activesupport')
-rw-r--r--activesupport/lib/active_support/ruby/shim.rb1
-rw-r--r--activesupport/test/core_ext/file_test.rb4
2 files changed, 5 insertions, 0 deletions
diff --git a/activesupport/lib/active_support/ruby/shim.rb b/activesupport/lib/active_support/ruby/shim.rb
index 1e49ccdade..f0db5b3021 100644
--- a/activesupport/lib/active_support/ruby/shim.rb
+++ b/activesupport/lib/active_support/ruby/shim.rb
@@ -17,3 +17,4 @@ require 'active_support/core_ext/string/conversions'
require 'active_support/core_ext/string/interpolation'
require 'active_support/core_ext/rexml'
require 'active_support/core_ext/time/conversions'
+require 'active_support/core_ext/file/path'
diff --git a/activesupport/test/core_ext/file_test.rb b/activesupport/test/core_ext/file_test.rb
index 26be694176..e1258b872e 100644
--- a/activesupport/test/core_ext/file_test.rb
+++ b/activesupport/test/core_ext/file_test.rb
@@ -57,6 +57,10 @@ class AtomicWriteTest < Test::Unit::TestCase
File.unlink(file_name) rescue nil
end
+ def test_responds_to_to_path
+ assert_equal __FILE__, File.open(__FILE__, "r").to_path
+ end
+
private
def file_name
"atomic.file"