diff options
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/test/controller/request_test.rb | 4 | ||||
-rw-r--r-- | actionpack/test/fixtures/multipart/bracketed_param | 5 |
2 files changed, 9 insertions, 0 deletions
diff --git a/actionpack/test/controller/request_test.rb b/actionpack/test/controller/request_test.rb index 4a43091823..1e6f6db8d8 100644 --- a/actionpack/test/controller/request_test.rb +++ b/actionpack/test/controller/request_test.rb @@ -652,6 +652,10 @@ class MultipartRequestParameterParsingTest < Test::Unit::TestCase assert_equal({ 'foo' => 'bar' }, params) end + def test_bracketed_param + assert_equal({ 'foo' => { 'baz' => 'bar'}}, process('bracketed_param')) + end + def test_text_file params = process('text_file') assert_equal %w(file foo), params.keys.sort diff --git a/actionpack/test/fixtures/multipart/bracketed_param b/actionpack/test/fixtures/multipart/bracketed_param new file mode 100644 index 0000000000..096bd8a192 --- /dev/null +++ b/actionpack/test/fixtures/multipart/bracketed_param @@ -0,0 +1,5 @@ +--AaB03x
+Content-Disposition: form-data; name="foo[baz]"
+
+bar
+--AaB03x--
|