From 5b66fba60fad48a704e369275a5eee58fbf3d6cf Mon Sep 17 00:00:00 2001 From: Leandro Facchinetti Date: Wed, 4 Jun 2014 23:17:16 -0300 Subject: Fix inverse associations test `InverseHasManyTests#test_parent_instance_should_be_shared_within_create_block_of_new_child` was mistakenly the same as `InverseHasManyTests#test_parent_instance_should_be_shared_within_build_block_of_new_child`. --- activerecord/test/cases/associations/inverse_associations_test.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activerecord/test') diff --git a/activerecord/test/cases/associations/inverse_associations_test.rb b/activerecord/test/cases/associations/inverse_associations_test.rb index 893030345f..a674a39d65 100644 --- a/activerecord/test/cases/associations/inverse_associations_test.rb +++ b/activerecord/test/cases/associations/inverse_associations_test.rb @@ -333,7 +333,7 @@ class InverseHasManyTests < ActiveRecord::TestCase def test_parent_instance_should_be_shared_within_create_block_of_new_child man = Man.first - interest = man.interests.build do |i| + interest = man.interests.create do |i| assert i.man.equal?(man), "Man of child should be the same instance as a parent" end assert interest.man.equal?(man), "Man of the child should still be the same instance as a parent" -- cgit v1.2.3