Skip to content
Browse files

Make sure about which is the first element of the query, fixes a post…

…gresql 8.4 failing test

Signed-off-by: José Valim <jose.valim@gmail.com>
  • Loading branch information...
1 parent 5b42acd commit 6898c167c3906b87dcf52cf6c088ae9f08f3ad22 @spastorino spastorino committed with josevalim Jun 9, 2010
Showing with 2 additions and 2 deletions.
  1. +2 −2 activerecord/test/cases/associations/cascaded_eager_loading_test.rb
View
4 activerecord/test/cases/associations/cascaded_eager_loading_test.rb
@@ -41,9 +41,9 @@ def test_eager_association_loading_with_hmt_does_not_table_name_collide_when_joi
def test_eager_association_loading_grafts_stashed_associations_to_correct_parent
assert_nothing_raised do
- Person.eager_load(:primary_contact => :primary_contact).where('primary_contacts_people_2.first_name = ?', 'Susan').all
+ Person.eager_load(:primary_contact => :primary_contact).where('primary_contacts_people_2.first_name = ?', 'Susan').order('primary_contacts_people_2.id').all
end
- assert_equal people(:michael), Person.eager_load(:primary_contact => :primary_contact).where('primary_contacts_people_2.first_name = ?', 'Susan').first
+ assert_equal people(:michael), Person.eager_load(:primary_contact => :primary_contact).where('primary_contacts_people_2.first_name = ?', 'Susan').order('primary_contacts_people_2.id').first
end
def test_eager_association_loading_with_cascaded_two_levels_with_two_has_many_associations

0 comments on commit 6898c16

Please sign in to comment.
Something went wrong with that request. Please try again.