aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases/associations
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2010-03-15 18:33:20 -0700
committerwycats <wycats@gmail.com>2010-03-15 18:36:08 -0700
commitdcf1441c0f8c405b1d44cce2e0fbf86a2396dcf1 (patch)
treeebf75a32db4e1c70db2a858c687ea2bc4efae4ca /activerecord/test/cases/associations
parent1def14309f32cc1c7d66b8625754ba2827410c96 (diff)
downloadrails-dcf1441c0f8c405b1d44cce2e0fbf86a2396dcf1.tar.gz
rails-dcf1441c0f8c405b1d44cce2e0fbf86a2396dcf1.tar.bz2
rails-dcf1441c0f8c405b1d44cce2e0fbf86a2396dcf1.zip
removing dead code from activerecord tests. [#4187 state:resolved]
Signed-off-by: wycats <wycats@gmail.com>
Diffstat (limited to 'activerecord/test/cases/associations')
-rw-r--r--activerecord/test/cases/associations/has_one_associations_test.rb9
-rw-r--r--activerecord/test/cases/associations/join_model_test.rb12
2 files changed, 0 insertions, 21 deletions
diff --git a/activerecord/test/cases/associations/has_one_associations_test.rb b/activerecord/test/cases/associations/has_one_associations_test.rb
index d5dbb88886..7372f2da1b 100644
--- a/activerecord/test/cases/associations/has_one_associations_test.rb
+++ b/activerecord/test/cases/associations/has_one_associations_test.rb
@@ -186,15 +186,6 @@ class HasOneAssociationsTest < ActiveRecord::TestCase
assert_equal account, firm.account
end
- def test_failing_build_association
- firm = Firm.new("name" => "GlobalMegaCorp")
- firm.save
-
- account = firm.build_account
- assert !account.save
- assert_equal ["can't be empty"], account.errors["credit_limit"]
- end
-
def test_build_association_twice_without_saving_affects_nothing
count_of_account = Account.count
firm = Firm.find(:first)
diff --git a/activerecord/test/cases/associations/join_model_test.rb b/activerecord/test/cases/associations/join_model_test.rb
index e9af5a60d8..8bdf8bcd55 100644
--- a/activerecord/test/cases/associations/join_model_test.rb
+++ b/activerecord/test/cases/associations/join_model_test.rb
@@ -52,18 +52,6 @@ class AssociationsJoinModelTest < ActiveRecord::TestCase
assert_equal 1, authors(:mary).unique_categorized_posts.find_all_by_title("So I was thinking").size
end
- def test_polymorphic_has_many
- assert posts(:welcome).taggings.include?(taggings(:welcome_general))
- end
-
- def test_polymorphic_has_one
- assert_equal taggings(:welcome_general), posts(:welcome).tagging
- end
-
- def test_polymorphic_belongs_to
- assert_equal posts(:welcome), posts(:welcome).taggings.first.taggable
- end
-
def test_polymorphic_has_many_going_through_join_model
assert_equal tags(:general), tag = posts(:welcome).tags.first
assert_no_queries do