提交 6e867a4d 编写于 作者: R Rafael Mendonça França

Merge pull request #13598 from zirni/remove_ar_warnings

Remove method redefined warnings for test suite

Closes #13526
......@@ -42,7 +42,7 @@ def test_join_conditions_added_to_join_clause
end
def test_join_association_conditions_support_string_and_arel_expressions
assert_equal 0, Author.joins(:welcome_posts_with_comment).count
assert_equal 0, Author.joins(:welcome_posts_with_one_comment).count
assert_equal 1, Author.joins(:welcome_posts_with_comments).count
end
......
......@@ -29,7 +29,7 @@ def ratings
has_many :thinking_posts, -> { where(:title => 'So I was thinking') }, :dependent => :delete_all, :class_name => 'Post'
has_many :welcome_posts, -> { where(:title => 'Welcome to the weblog') }, :class_name => 'Post'
has_many :welcome_posts_with_comment,
has_many :welcome_posts_with_one_comment,
-> { where(title: 'Welcome to the weblog').where('comments_count = ?', 1) },
class_name: 'Post'
has_many :welcome_posts_with_comments,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册