aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/template
diff options
context:
space:
mode:
authorSantiago Pastorino <santiago@wyeworks.com>2012-02-21 14:55:34 -0200
committerSantiago Pastorino <santiago@wyeworks.com>2012-02-21 14:55:34 -0200
commit92a7296a5deb109d054b32d96fa1a74f0859a81b (patch)
treee85eee6e887e5d324bad8977e59bf5ca1671975a /actionpack/test/template
parent67a5157974ed9809570e2b29b69b59b85a4c7c52 (diff)
downloadrails-92a7296a5deb109d054b32d96fa1a74f0859a81b.tar.gz
rails-92a7296a5deb109d054b32d96fa1a74f0859a81b.tar.bz2
rails-92a7296a5deb109d054b32d96fa1a74f0859a81b.zip
Restore lookup formats to the previous value after searching for the failing view
Diffstat (limited to 'actionpack/test/template')
-rw-r--r--actionpack/test/template/render_test.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/actionpack/test/template/render_test.rb b/actionpack/test/template/render_test.rb
index e4ce756bf8..3b461f3529 100644
--- a/actionpack/test/template/render_test.rb
+++ b/actionpack/test/template/render_test.rb
@@ -52,10 +52,11 @@ module RenderTestCases
end
def test_render_template_with_a_missing_partial_of_another_format
+ @view.lookup_context.freeze_formats([:html])
assert_raise ActionView::Template::Error, "Missing partial /missing with {:locale=>[:en], :formats=>[:json], :handlers=>[:erb, :builder]}" do
- @view.lookup_context.freeze_formats([:html])
@view.render(:template => "with_format", :formats => [:json])
end
+ assert_equal [:html], @view.lookup_context.formats
end
def test_render_file_with_locale