aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test
diff options
context:
space:
mode:
authorArthur Neves <arthurnn@gmail.com>2016-02-02 23:37:31 -0500
committerArthur Neves <arthurnn@gmail.com>2016-02-02 23:37:31 -0500
commitbcd0c8cfc250039ddc145c3302633c4890880930 (patch)
treef1c0fa68437c66fcdec6d9aa477e7e5eb5da76a6 /activerecord/test
parent522099a13ffea611dfb37d4d22da62eb8cb81c12 (diff)
parent9c9fb19b9eda46a76d7ce4fd6cb9cc94bd965e62 (diff)
downloadrails-bcd0c8cfc250039ddc145c3302633c4890880930.tar.gz
rails-bcd0c8cfc250039ddc145c3302633c4890880930.tar.bz2
rails-bcd0c8cfc250039ddc145c3302633c4890880930.zip
Merge pull request #20997 from himesh-r/issue-20995
Changed id-writer to save join table records based on association primary key #20995.
Diffstat (limited to 'activerecord/test')
-rw-r--r--activerecord/test/cases/associations/has_many_through_associations_test.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/test/cases/associations/has_many_through_associations_test.rb b/activerecord/test/cases/associations/has_many_through_associations_test.rb
index 226ecf5447..bb8c9fa19c 100644
--- a/activerecord/test/cases/associations/has_many_through_associations_test.rb
+++ b/activerecord/test/cases/associations/has_many_through_associations_test.rb
@@ -884,7 +884,7 @@ class HasManyThroughAssociationsTest < ActiveRecord::TestCase
def test_collection_singular_ids_setter_raises_exception_when_invalid_ids_set
company = companies(:rails_core)
ids = [Developer.first.id, -9999]
- assert_raises(ActiveRecord::RecordNotFound) {company.developer_ids= ids}
+ assert_raises(ActiveRecord::AssociationTypeMismatch) {company.developer_ids= ids}
end
def test_build_a_model_from_hm_through_association_with_where_clause