diff options
author | Pratik Naik <pratiknaik@gmail.com> | 2008-04-21 03:38:16 +0100 |
---|---|---|
committer | Pratik Naik <pratiknaik@gmail.com> | 2008-04-21 03:45:38 +0100 |
commit | 2b69840e5efba885c8ec6281d5b8a56fcabff283 (patch) | |
tree | 6535bda8b27784e097a0fe44cf692e150e3ad2bb /actionpack/test/controller/new_render_test.rb | |
parent | caa03a5c870c6a03a35f6dcfaf040a6d689eaee2 (diff) | |
download | rails-2b69840e5efba885c8ec6281d5b8a56fcabff283.tar.gz rails-2b69840e5efba885c8ec6281d5b8a56fcabff283.tar.bz2 rails-2b69840e5efba885c8ec6281d5b8a56fcabff283.zip |
Remove ActionController::Base#view_controller_internals
Get rid of ActionController::Base#view_controller_internals flag and
use @@protected_view_variables for storing the list of controller
specific instance variables which should be inaccessible inside views.
Diffstat (limited to 'actionpack/test/controller/new_render_test.rb')
-rw-r--r-- | actionpack/test/controller/new_render_test.rb | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/actionpack/test/controller/new_render_test.rb b/actionpack/test/controller/new_render_test.rb index 80cf09e5f3..9f9d861d32 100644 --- a/actionpack/test/controller/new_render_test.rb +++ b/actionpack/test/controller/new_render_test.rb @@ -529,26 +529,10 @@ class NewRenderTest < Test::Unit::TestCase end def test_access_to_request_in_view - view_internals_old_value = ActionController::Base.view_controller_internals - - ActionController::Base.view_controller_internals = false - ActionController::Base.protected_variables_cache = nil - - get :hello_world - assert !assigns.include?('_request'), '_request should not be in assigns' - assert !assigns.include?('request'), 'request should not be in assigns' - - ActionController::Base.view_controller_internals = true - ActionController::Base.protected_variables_cache = nil - get :hello_world assert !assigns.include?('request'), 'request should not be in assigns' assert_kind_of ActionController::AbstractRequest, assigns['_request'] assert_kind_of ActionController::AbstractRequest, @response.template.request - - ensure - ActionController::Base.view_controller_internals = view_internals_old_value - ActionController::Base.protected_variables_cache = nil end def test_render_xml |