Rails 2.3.3.1

Update to latest Rails.
A little bit of jiggery-pokery is involved, since they
neglected to re-include vendored Rack in this release.
This commit is contained in:
Jacques Distler 2009-08-04 10:16:03 -05:00
parent 329fafafce
commit 664552ac02
257 changed files with 4346 additions and 1682 deletions

View file

@ -240,6 +240,14 @@ class IntegrationProcessTest < ActionController::IntegrationTest
render :text => "foo: #{params[:foo]}", :status => 200
end
def post_with_multiparameter_params
render :text => "foo(1i): #{params[:"foo(1i)"]}, foo(2i): #{params[:"foo(2i)"]}", :status => 200
end
def multipart_post_with_multiparameter_params
render :text => "foo(1i): #{params[:"foo(1i)"]}, foo(2i): #{params[:"foo(2i)"]}, filesize: #{params[:file].size}", :status => 200
end
def post
render :text => "Created", :status => 201
end
@ -255,6 +263,8 @@ class IntegrationProcessTest < ActionController::IntegrationTest
end
end
FILES_DIR = File.dirname(__FILE__) + '/../fixtures/multipart'
def test_get
with_test_route_set do
get '/get'
@ -360,6 +370,24 @@ class IntegrationProcessTest < ActionController::IntegrationTest
end
end
def test_post_with_multiparameter_attribute_parameters
with_test_route_set do
post '/post_with_multiparameter_params', :"foo(1i)" => "bar", :"foo(2i)" => "baz"
assert_equal 200, status
assert_equal "foo(1i): bar, foo(2i): baz", response.body
end
end
def test_multipart_post_with_multiparameter_attribute_parameters
with_test_route_set do
post '/multipart_post_with_multiparameter_params', :"foo(1i)" => "bar", :"foo(2i)" => "baz", :file => fixture_file_upload(FILES_DIR + "/mona_lisa.jpg", "image/jpg")
assert_equal 200, status
assert_equal "foo(1i): bar, foo(2i): baz, filesize: 159528", response.body
end
end
def test_head
with_test_route_set do
head '/get'