aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSantiago Pastorino <santiago@wyeworks.com>2012-04-23 16:30:38 -0700
committerSantiago Pastorino <santiago@wyeworks.com>2012-04-23 16:30:38 -0700
commitdb6787af681a74499339bc4b9f83d817c6353410 (patch)
tree5451715ba849f0db9e121ef9e6591eb8545241da
parent0f5af608d99c6086ed95798bf93b44f4254f7c18 (diff)
parent0f3fd78953104c010edfd971e5f7da2efcd43def (diff)
downloadrails-db6787af681a74499339bc4b9f83d817c6353410.tar.gz
rails-db6787af681a74499339bc4b9f83d817c6353410.tar.bz2
rails-db6787af681a74499339bc4b9f83d817c6353410.zip
Merge pull request #5946 from sikachu/3-2-stable-fix-merge-conflict
Fix broken test from the earlier merge conflict
-rw-r--r--actionpack/test/template/render_test.rb20
1 files changed, 11 insertions, 9 deletions
diff --git a/actionpack/test/template/render_test.rb b/actionpack/test/template/render_test.rb
index 73df41462f..bfeb6aee1a 100644
--- a/actionpack/test/template/render_test.rb
+++ b/actionpack/test/template/render_test.rb
@@ -166,7 +166,7 @@ module RenderTestCases
def test_render_partial_with_incompatible_object
e = assert_raises(ArgumentError) { @view.render(:partial => nil) }
- assert_equal "'#{nil.inspect}' is not an ActiveModel-compatible object. It must implement :to_partial_path.", e.message
+ assert_equal "'#{nil.inspect}' is not an ActiveModel-compatible object that returns a valid partial path.", e.message
end
def test_render_partial_with_errors
@@ -470,16 +470,18 @@ class LazyViewRenderTest < ActiveSupport::TestCase
end
end
- def test_render_utf8_template_with_incompatible_external_encoding
- with_external_encoding Encoding::SHIFT_JIS do
- e = assert_raises(ActionView::Template::Error) { @view.render(:file => "test/utf8", :formats => [:html], :layouts => "layouts/yield") }
- assert_match 'Your template was not saved as valid Shift_JIS', e.original_exception.message
+ def test_render_utf8_template_with_incompatible_external_encoding
+ with_external_encoding Encoding::SHIFT_JIS do
+ e = assert_raises(ActionView::Template::Error) { @view.render(:file => "test/utf8", :formats => [:html], :layouts => "layouts/yield") }
+ assert_match 'Your template was not saved as valid Shift_JIS', e.original_exception.message
+ end
end
- def test_render_utf8_template_with_partial_with_incompatible_encoding
- with_external_encoding Encoding::SHIFT_JIS do
- e = assert_raises(ActionView::Template::Error) { @view.render(:file => "test/utf8_magic_with_bare_partial", :formats => [:html], :layouts => "layouts/yield") }
- assert_match 'Your template was not saved as valid Shift_JIS', e.original_exception.message
+ def test_render_utf8_template_with_partial_with_incompatible_encoding
+ with_external_encoding Encoding::SHIFT_JIS do
+ e = assert_raises(ActionView::Template::Error) { @view.render(:file => "test/utf8_magic_with_bare_partial", :formats => [:html], :layouts => "layouts/yield") }
+ assert_match 'Your template was not saved as valid Shift_JIS', e.original_exception.message
+ end
end
def with_external_encoding(encoding)