diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2014-08-01 10:07:38 -0700 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2014-08-01 10:07:38 -0700 |
commit | 702ad710b57bef45b081ebf42e6fa70820fdd810 (patch) | |
tree | d6b1542c65b2e80d3e921d04e58d77b60d5b92d2 /activesupport/test/core_ext/object | |
parent | 20405e516b031db4d8230014d1dcf9601ed0a0f8 (diff) | |
download | rails-702ad710b57bef45b081ebf42e6fa70820fdd810.tar.gz rails-702ad710b57bef45b081ebf42e6fa70820fdd810.tar.bz2 rails-702ad710b57bef45b081ebf42e6fa70820fdd810.zip |
Added Object#self which returns the object itself
Diffstat (limited to 'activesupport/test/core_ext/object')
-rw-r--r-- | activesupport/test/core_ext/object/self_test.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/activesupport/test/core_ext/object/self_test.rb b/activesupport/test/core_ext/object/self_test.rb new file mode 100644 index 0000000000..751199e41c --- /dev/null +++ b/activesupport/test/core_ext/object/self_test.rb @@ -0,0 +1,9 @@ +require 'abstract_unit' +require 'active_support/core_ext/object' + +class Object::SelfTest < ActiveSupport::TestCase + test 'self returns self' do + object = 'fun' + assert_equal object, object.self + end +end |