diff options
author | Josh Kalderimis <josh.kalderimis@gmail.com> | 2010-11-19 18:29:33 +0100 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-11-20 19:40:29 +0100 |
commit | d7db6a88734c3b666f4b85f266d223eff408b294 (patch) | |
tree | ccfa0ed1a0e92b9c3324bf92f92391f2d20be95c /actionpack/lib/action_controller/test_case.rb | |
parent | 8d8062190ddd0452088f6ea917267ed993a70990 (diff) | |
download | rails-d7db6a88734c3b666f4b85f266d223eff408b294.tar.gz rails-d7db6a88734c3b666f4b85f266d223eff408b294.tar.bz2 rails-d7db6a88734c3b666f4b85f266d223eff408b294.zip |
class inheritable attributes is used no more! all internal use of class inheritable has been changed to class_attribute. class inheritable attributes has been deprecated.
Signed-off-by: José Valim <jose.valim@gmail.com>
Diffstat (limited to 'actionpack/lib/action_controller/test_case.rb')
-rw-r--r-- | actionpack/lib/action_controller/test_case.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/actionpack/lib/action_controller/test_case.rb b/actionpack/lib/action_controller/test_case.rb index 2b2f647d32..0f43527a56 100644 --- a/actionpack/lib/action_controller/test_case.rb +++ b/actionpack/lib/action_controller/test_case.rb @@ -1,6 +1,7 @@ require 'rack/session/abstract/id' require 'active_support/core_ext/object/blank' require 'active_support/core_ext/object/to_query' +require 'active_support/core_ext/class/attribute' module ActionController module TemplateAssertions @@ -325,11 +326,11 @@ module ActionController def controller_class=(new_class) prepare_controller_class(new_class) if new_class - write_inheritable_attribute(:controller_class, new_class) + self._controller_class = new_class end def controller_class - if current_controller_class = read_inheritable_attribute(:controller_class) + if current_controller_class = self._controller_class current_controller_class else self.controller_class = determine_default_controller_class(name) @@ -442,6 +443,7 @@ module ActionController included do include ActionController::TemplateAssertions include ActionDispatch::Assertions + class_attribute :_controller_class setup :setup_controller_request_and_response end |