aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases
diff options
context:
space:
mode:
Diffstat (limited to 'activerecord/test/cases')
-rw-r--r--activerecord/test/cases/associations/has_many_associations_test.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/activerecord/test/cases/associations/has_many_associations_test.rb b/activerecord/test/cases/associations/has_many_associations_test.rb
index 1bc9c39c19..dada2d1603 100644
--- a/activerecord/test/cases/associations/has_many_associations_test.rb
+++ b/activerecord/test/cases/associations/has_many_associations_test.rb
@@ -1080,5 +1080,9 @@ class HasManyAssociationsTest < ActiveRecord::TestCase
end
end
+ def test_sending_new_to_association_proxy_should_have_same_effect_as_calling_new
+ clients_assoc = companies(:first_firm).clients
+ assert_equal clients_assoc.new.attributes, clients_assoc.send(:new).attributes
+ end
end