Permalink
Browse files

Remove yaml Proc param parser test

I don't believe this test is exercising any explicit params_parser
behavior that the other two Proc tests aren't already doing.  Given
that we now know it's a bad idea to load user input via YAML.load,
somebody reading this test might get a dangerous idea about building
out a YAML params parser.
  • Loading branch information...
1 parent 744307e commit c302741d8f9c34acdeae773184b30c2ae9b58e73 @bemurphy bemurphy committed Jan 29, 2013
Showing with 0 additions and 13 deletions.
  1. +0 −13 actionpack/test/controller/webservice_test.rb
View
13 actionpack/test/controller/webservice_test.rb
@@ -129,19 +129,6 @@ def test_post_xml_using_a_disallowed_type_attribute
$stderr = STDERR
end
- def test_register_and_use_yaml
- with_test_route_set do
- with_params_parsers Mime::YAML => Proc.new { |d| YAML.load(d) } do
- post "/", {"entry" => "loaded from yaml"}.to_yaml,
- {'CONTENT_TYPE' => 'application/x-yaml'}
-
- assert_equal 'entry', @controller.response.body
- assert @controller.params.has_key?(:entry)
- assert_equal 'loaded from yaml', @controller.params["entry"]
- end
- end
- end
-
def test_register_and_use_xml_simple
with_test_route_set do
with_params_parsers Mime::XML => Proc.new { |data| Hash.from_xml(data)['request'].with_indifferent_access } do

0 comments on commit c302741

Please sign in to comment.