aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases/associations/inner_join_association_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activerecord/test/cases/associations/inner_join_association_test.rb')
-rw-r--r--activerecord/test/cases/associations/inner_join_association_test.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/activerecord/test/cases/associations/inner_join_association_test.rb b/activerecord/test/cases/associations/inner_join_association_test.rb
index be0f5714f3..ca0620dc3b 100644
--- a/activerecord/test/cases/associations/inner_join_association_test.rb
+++ b/activerecord/test/cases/associations/inner_join_association_test.rb
@@ -115,19 +115,19 @@ class InnerJoinAssociationTest < ActiveRecord::TestCase
scope = Post.joins(:special_comments).where(id: posts(:sti_comments).id)
# The join should match SpecialComment and its subclasses only
- assert_predicate scope.where("comments.type" => "Comment"), :empty?
- assert_not_predicate scope.where("comments.type" => "SpecialComment"), :empty?
- assert_not_predicate scope.where("comments.type" => "SubSpecialComment"), :empty?
+ assert_empty scope.where("comments.type" => "Comment")
+ assert_not_empty scope.where("comments.type" => "SpecialComment")
+ assert_not_empty scope.where("comments.type" => "SubSpecialComment")
end
def test_find_with_conditions_on_reflection
- assert_not_predicate posts(:welcome).comments, :empty?
+ assert_not_empty posts(:welcome).comments
assert Post.joins(:nonexistent_comments).where(id: posts(:welcome).id).empty? # [sic!]
end
def test_find_with_conditions_on_through_reflection
- assert_not_predicate posts(:welcome).tags, :empty?
- assert_predicate Post.joins(:misc_tags).where(id: posts(:welcome).id), :empty?
+ assert_not_empty posts(:welcome).tags
+ assert_empty Post.joins(:misc_tags).where(id: posts(:welcome).id)
end
test "the default scope of the target is applied when joining associations" do