From 3f445b316d34a49a8b6f27bde72979828baefaa8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Valim?= Date: Tue, 28 Jul 2009 15:49:59 +0200 Subject: Refactor Responder to only calculate available mime types. Those are sent to the controller that knows what to do with it (render a block or call default render). Signed-off-by: Yehuda Katz --- actionpack/test/controller/mime_responds_test.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'actionpack/test/controller') diff --git a/actionpack/test/controller/mime_responds_test.rb b/actionpack/test/controller/mime_responds_test.rb index 93ca34c41c..bee327998b 100644 --- a/actionpack/test/controller/mime_responds_test.rb +++ b/actionpack/test/controller/mime_responds_test.rb @@ -436,9 +436,9 @@ class MimeControllerTest < ActionController::TestCase def test_render_action_for_html @controller.instance_eval do def render(*args) - unless args.empty? - @action = args.first[:action] || action_name - end + @action = args.first[:action] unless args.empty? + @action ||= action_name + response.body = "#{@action} - #{@template.formats}" end end -- cgit v1.2.3