diff options
author | Ryuta Kamizono <kamipo@gmail.com> | 2017-04-26 21:24:28 +0900 |
---|---|---|
committer | Ryuta Kamizono <kamipo@gmail.com> | 2017-04-26 22:41:32 +0900 |
commit | 111ae374015c43a69a2d3d2bf74466c4af8d975f (patch) | |
tree | 878d15a42280423f47bd0cde734823e5ac329292 /activerecord/test | |
parent | 801b33a4812c937a7e726d4060e2e3e9361c56fa (diff) | |
download | rails-111ae374015c43a69a2d3d2bf74466c4af8d975f.tar.gz rails-111ae374015c43a69a2d3d2bf74466c4af8d975f.tar.bz2 rails-111ae374015c43a69a2d3d2bf74466c4af8d975f.zip |
Remove useless test case
Cannot call private methods in `@klass` against `CollectionProxy`
(inherites `Relation`) because using `public_send` in `method_missing`.
Diffstat (limited to 'activerecord/test')
-rw-r--r-- | activerecord/test/cases/associations/has_many_associations_test.rb | 5 | ||||
-rw-r--r-- | activerecord/test/models/company.rb | 8 |
2 files changed, 0 insertions, 13 deletions
diff --git a/activerecord/test/cases/associations/has_many_associations_test.rb b/activerecord/test/cases/associations/has_many_associations_test.rb index 7429eb7425..6a479a344c 100644 --- a/activerecord/test/cases/associations/has_many_associations_test.rb +++ b/activerecord/test/cases/associations/has_many_associations_test.rb @@ -2037,11 +2037,6 @@ class HasManyAssociationsTest < ActiveRecord::TestCase assert_equal client_association.new.attributes, client_association.send(:new).attributes end - def test_respond_to_private_class_methods - client_association = companies(:first_firm).clients - assert !client_association.respond_to?(:private_method) - end - def test_creating_using_primary_key firm = Firm.all.merge!(order: "id").first client = firm.clients_using_primary_key.create!(name: "test") diff --git a/activerecord/test/models/company.rb b/activerecord/test/models/company.rb index 20e37710e7..d269a95e8c 100644 --- a/activerecord/test/models/company.rb +++ b/activerecord/test/models/company.rb @@ -170,14 +170,6 @@ class Client < Company def overwrite_to_raise end - - class << self - private - - def private_method - "darkness" - end - end end class ExclusivelyDependentFirm < Company |