diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2013-10-10 14:40:24 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2013-10-10 14:40:24 -0300 |
commit | 9639f65af534f7d9afeb359c30214fd6b4d71694 (patch) | |
tree | 52f4b4e25d370ad5b017259e4a2cb01f48c4c6b9 /activerecord/test/cases/associations/inverse_associations_test.rb | |
parent | 7ed5bdc834479c39e3b0ad5a38bcffe27983c10d (diff) | |
download | rails-9639f65af534f7d9afeb359c30214fd6b4d71694.tar.gz rails-9639f65af534f7d9afeb359c30214fd6b4d71694.tar.bz2 rails-9639f65af534f7d9afeb359c30214fd6b4d71694.zip |
Revert "Merge pull request #12443 from arthurnn/add_inverse_of_add_target"
This reverts commit 7ed5bdc834479c39e3b0ad5a38bcffe27983c10d, reversing
changes made to 31c79e291f42b1d862df06c552fe002864aae705.
Reason: this caused a regression when the associated record is creted in
a before_create callback.
See https://github.com/rails/rails/pull/12413#issuecomment-25848163
Diffstat (limited to 'activerecord/test/cases/associations/inverse_associations_test.rb')
-rw-r--r-- | activerecord/test/cases/associations/inverse_associations_test.rb | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/activerecord/test/cases/associations/inverse_associations_test.rb b/activerecord/test/cases/associations/inverse_associations_test.rb index a44b78f200..51e466ecac 100644 --- a/activerecord/test/cases/associations/inverse_associations_test.rb +++ b/activerecord/test/cases/associations/inverse_associations_test.rb @@ -290,19 +290,6 @@ class InverseHasManyTests < ActiveRecord::TestCase def test_trying_to_use_inverses_that_dont_exist_should_raise_an_error assert_raise(ActiveRecord::InverseOfAssociationNotFoundError) { Man.find(:first).secret_interests } end - - def test_child_instance_should_point_to_parent_without_saving - man = Man.new - i = Interest.create(:topic => 'Industrial Revolution Re-enactment') - - man.interests << i - assert_not_nil i.man - - i.man.name = "Charles" - assert_equal i.man.name, man.name - - assert !man.persisted? - end end class InverseBelongsToTests < ActiveRecord::TestCase |