diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2008-11-27 21:04:24 +0100 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2008-11-27 21:04:24 +0100 |
commit | 5fa0457542b0ff541d0a80ff8c3561eec8e35959 (patch) | |
tree | 02264b718d54ffb2a513ad9a05bf2c7a6f572589 /actionpack/test/template/render_test.rb | |
parent | 6fa9957e0e83f327aaffe34679a5752fc2343fae (diff) | |
download | rails-5fa0457542b0ff541d0a80ff8c3561eec8e35959.tar.gz rails-5fa0457542b0ff541d0a80ff8c3561eec8e35959.tar.bz2 rails-5fa0457542b0ff541d0a80ff8c3561eec8e35959.zip |
Revert "Super lazy load view paths in development mode (no indexing or caching at all). Switch layout finders to use view path api to take advantage of cache." as it killed dev mode reloading.
This reverts commit 4d910b033379727e5e7355590c50c72fc75e56db.
Diffstat (limited to 'actionpack/test/template/render_test.rb')
-rw-r--r-- | actionpack/test/template/render_test.rb | 17 |
1 files changed, 2 insertions, 15 deletions
diff --git a/actionpack/test/template/render_test.rb b/actionpack/test/template/render_test.rb index 28d38b0c76..b316d5c23e 100644 --- a/actionpack/test/template/render_test.rb +++ b/actionpack/test/template/render_test.rb @@ -4,9 +4,7 @@ require 'controller/fake_models' class ViewRenderTest < Test::Unit::TestCase def setup @assigns = { :secret => 'in the sauce' } - view_paths = ActionController::Base.view_paths - @view = ActionView::Base.new(view_paths, @assigns) - assert view_paths.first.loaded? + @view = ActionView::Base.new(ActionController::Base.view_paths, @assigns) end def test_render_file @@ -159,7 +157,7 @@ class ViewRenderTest < Test::Unit::TestCase end def test_render_fallbacks_to_erb_for_unknown_types - assert_equal "Hello, World!", @view.render(:inline => "Hello, World!", :type => :bar) + assert_equal "Hello, World!", @view.render(:inline => "Hello, World!", :type => :foo) end CustomHandler = lambda do |template| @@ -198,14 +196,3 @@ class ViewRenderTest < Test::Unit::TestCase @view.render(:file => "test/nested_layout.erb", :layout => "layouts/yield") end end - -class LazyViewRenderTest < ViewRenderTest - # Test the same thing as above, but make sure the view path - # is not eager loaded - def setup - @assigns = { :secret => 'in the sauce' } - view_paths = ActionView::Base.process_view_paths(FIXTURE_LOAD_PATH) - @view = ActionView::Base.new(view_paths, @assigns) - assert !view_paths.first.loaded? - end -end |