From 9ddd7fbd2478883f9928095014294903942536f6 Mon Sep 17 00:00:00 2001 From: Jan Maurits Faber Date: Sat, 6 Nov 2010 15:35:17 +0100 Subject: [PATCH 2/2] Added support for Erubis <%== tag + test --- .../controller/new_base/render_template_test.rb | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-) diff --git a/actionpack/test/controller/new_base/render_template_test.rb b/actionpack/test/controller/new_base/render_template_test.rb index d31193a..9899036 100644 --- a/actionpack/test/controller/new_base/render_template_test.rb +++ b/actionpack/test/controller/new_base/render_template_test.rb @@ -9,6 +9,7 @@ module RenderTemplate "locals.html.erb" => "The secret is <%= secret %>", "xml_template.xml.builder" => "xml.html do\n xml.p 'Hello'\nend", "with_raw.html.erb" => "Hello <%=raw 'this is raw' %>", + "with_implicit_raw.html.erb"=> "Hello <%== 'this is also raw' %>", "test/with_json.html.erb" => "<%= render :template => 'test/with_json.json' %>", "test/with_json.json.erb" => "<%= render :template => 'test/final' %>", "test/final.json.erb" => "{ final: json }", @@ -51,6 +52,10 @@ module RenderTemplate render :template => "with_raw" end + def with_implicit_raw + render :template => "with_implicit_raw" + end + def with_error render :template => "test/with_error" end @@ -99,6 +104,11 @@ module RenderTemplate assert_body "Hello this is raw" assert_status 200 + + get :with_implicit_raw + + assert_body "Hello this is also raw" + assert_status 200 end test "rendering a template with renders another template with other format that renders other template in the same format" do -- 1.7.3.1