Permalink
Browse files

Merge pull request #29324 from koic/remove_redundant_test_find_all_wi…

…th_join

Remove the redundant `test_find_all_with_join` in AR
  • Loading branch information...
eileencodes committed Jun 2, 2017
2 parents e935a6c + 2b394c8 commit 3d31c05254fafd0aad556728ae85efc30ae1a272
Showing with 0 additions and 10 deletions.
  1. +0 −10 activerecord/test/cases/finder_test.rb
@@ -1023,16 +1023,6 @@ def test_find_with_bad_sql
assert_raise(ActiveRecord::StatementInvalid) { Topic.find_by_sql "select 1 from badtable" }
end
def test_find_all_with_join
developers_on_project_one = Developer.
joins("LEFT JOIN developers_projects ON developers.id = developers_projects.developer_id").
where("project_id=1").to_a
assert_equal 3, developers_on_project_one.length
developer_names = developers_on_project_one.map(&:name)
assert_includes developer_names, "David"
assert_includes developer_names, "Jamis"
end
def test_joins_dont_clobber_id
first = Firm.
joins("INNER JOIN companies clients ON clients.firm_id = companies.id").

0 comments on commit 3d31c05

Please sign in to comment.