From 487312515c09c5dbc7306329805f2eebfed1d630 Mon Sep 17 00:00:00 2001 From: Yehuda Katz + Carl Lerche Date: Wed, 17 Jun 2009 12:36:15 -0700 Subject: [PATCH] RJS doesn't render with an HTML layout by default --- actionpack/lib/action_controller/base/compatibility.rb | 1 + actionpack/test/controller/mime_responds_test.rb | 8 +++----- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/actionpack/lib/action_controller/base/compatibility.rb b/actionpack/lib/action_controller/base/compatibility.rb index 085db284e4..cd4b72b1c6 100644 --- a/actionpack/lib/action_controller/base/compatibility.rb +++ b/actionpack/lib/action_controller/base/compatibility.rb @@ -124,6 +124,7 @@ module ActionController super rescue ActionView::MissingTemplate _find_by_parts(_layout({}), {}) + nil end def performed? diff --git a/actionpack/test/controller/mime_responds_test.rb b/actionpack/test/controller/mime_responds_test.rb index 04d6c4173a..c9994ee013 100644 --- a/actionpack/test/controller/mime_responds_test.rb +++ b/actionpack/test/controller/mime_responds_test.rb @@ -375,11 +375,9 @@ class MimeControllerTest < ActionController::TestCase end def test_rjs_type_skips_layout - pending(:new_base) do - @request.accept = "text/javascript" - get :all_types_with_layout - assert_equal 'RJS for all_types_with_layout', @response.body - end + @request.accept = "text/javascript" + get :all_types_with_layout + assert_equal 'RJS for all_types_with_layout', @response.body end def test_html_type_with_layout