diff options
Diffstat (limited to 'actionpack/lib/action_controller/metal/testing.rb')
-rw-r--r-- | actionpack/lib/action_controller/metal/testing.rb | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/actionpack/lib/action_controller/metal/testing.rb b/actionpack/lib/action_controller/metal/testing.rb index 4b8c452d50..01fd55e1dd 100644 --- a/actionpack/lib/action_controller/metal/testing.rb +++ b/actionpack/lib/action_controller/metal/testing.rb @@ -14,18 +14,10 @@ module ActionController cookies.write(@_response) end @_response.prepare! - set_test_assigns + @assigns = respond_to?(:view_assigns) ? view_assigns : {} ret end - def set_test_assigns - @assigns = {} - (instance_variable_names - self.class.protected_instance_variables).each do |var| - name, value = var[1..-1], instance_variable_get(var) - @assigns[name] = value - end - end - # TODO : Rewrite tests using controller.headers= to use Rack env def headers=(new_headers) @_response ||= ActionDispatch::Response.new |