aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/controller/render_test.rb
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2008-11-20 08:52:48 +0100
committerDavid Heinemeier Hansson <david@loudthinking.com>2008-11-20 08:52:48 +0100
commit206c5643aae40b0884d42fdb8caeb3f763936fa9 (patch)
tree608f5cc7daab7b58b3d159429c595303e7e1c7d4 /actionpack/test/controller/render_test.rb
parentfb1eebac940d0648d1640d20a24f085d901d6f30 (diff)
parent20a346170cf3922d16e265487cfb1abcc85383c1 (diff)
downloadrails-206c5643aae40b0884d42fdb8caeb3f763936fa9.tar.gz
rails-206c5643aae40b0884d42fdb8caeb3f763936fa9.tar.bz2
rails-206c5643aae40b0884d42fdb8caeb3f763936fa9.zip
Merge branch 'master' of git@github.com:rails/rails
Diffstat (limited to 'actionpack/test/controller/render_test.rb')
-rw-r--r--actionpack/test/controller/render_test.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/actionpack/test/controller/render_test.rb b/actionpack/test/controller/render_test.rb
index 462fba7045..d5320596d5 100644
--- a/actionpack/test/controller/render_test.rb
+++ b/actionpack/test/controller/render_test.rb
@@ -246,6 +246,15 @@ class TestController < ActionController::Base
:locals => { :local_name => name }
end
+ def helper_method_to_render_to_string(*args)
+ render_to_string(*args)
+ end
+ helper_method :helper_method_to_render_to_string
+
+ def render_html_only_partial_within_inline
+ render :inline => "Hello world <%= helper_method_to_render_to_string :partial => 'test/partial_with_only_html_version' %>"
+ end
+
def formatted_html_erb
end
@@ -932,6 +941,11 @@ class RenderTest < ActionController::TestCase
assert_equal "Goodbye, Local David", @response.body
end
+ def test_rendering_html_only_partial_within_inline_with_js
+ get :render_html_only_partial_within_inline, :format => :js
+ assert_equal "Hello world partial with only html version", @response.body
+ end
+
def test_should_render_formatted_template
get :formatted_html_erb
assert_equal 'formatted html erb', @response.body