diff options
Diffstat (limited to 'actionpack/test/controller')
-rw-r--r-- | actionpack/test/controller/test_test.rb | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/actionpack/test/controller/test_test.rb b/actionpack/test/controller/test_test.rb index 677a933ccb..1da5298900 100644 --- a/actionpack/test/controller/test_test.rb +++ b/actionpack/test/controller/test_test.rb @@ -767,9 +767,8 @@ XML end def test_action_dispatch_uploaded_file_upload - filename = 'mona_lisa.jpg' - path = "#{FILES_DIR}/#{filename}" - post :test_file_upload, :file => ActionDispatch::Http::UploadedFile.new(:filename => path, :type => "image/jpg", :tempfile => File.open(path)) + tf = Class.new { def size; 159528 end } + post :test_file_upload, :file => ActionDispatch::Http::UploadedFile.new(:tempfile => tf.new) assert_equal '159528', @response.body end |