From 16571f9c42e2717eeb8bf7c915911fa1ca714525 Mon Sep 17 00:00:00 2001 From: dmathieu <42@dmathieu.com> Date: Thu, 26 May 2011 08:09:38 +0200 Subject: don't raise an exception if the format isn't recognized Fixed while traveling to heuruko --- actionpack/test/controller/mime_responds_test.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'actionpack/test/controller/mime_responds_test.rb') diff --git a/actionpack/test/controller/mime_responds_test.rb b/actionpack/test/controller/mime_responds_test.rb index 4a5e597500..26270571cf 100644 --- a/actionpack/test/controller/mime_responds_test.rb +++ b/actionpack/test/controller/mime_responds_test.rb @@ -498,6 +498,12 @@ class RespondToControllerTest < ActionController::TestCase assert_equal '
Hello iPhone future from iPhone!
', @response.body assert_equal "text/html", @response.content_type end + + def test_invalid_format + get :using_defaults, :format => "invalidformat" + assert_equal " ", @response.body + assert_equal "text/html", @response.content_type + end end class RespondWithController < ActionController::Base -- cgit v1.2.3