From 0f35c7d1c21f395f74782bc8d63f9828bd538d12 Mon Sep 17 00:00:00 2001 From: Eric Davis Date: Fri, 3 Jun 2011 14:11:08 -0700 Subject: [PATCH] Fix test on 1.9.2 postgres. Multiple records were found and postgres was returning them in a different order than what the test assumed. --- test/unit/activity_test.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/unit/activity_test.rb b/test/unit/activity_test.rb index 9cc67ea7..db1bcb2b 100644 --- a/test/unit/activity_test.rb +++ b/test/unit/activity_test.rb @@ -79,7 +79,7 @@ class ActivityTest < ActiveSupport::TestCase assert_kind_of Array, events assert events.include?(Attachment.find_by_container_type_and_container_id('Project', 1).last_journal) - assert events.include?(Attachment.find_by_container_type_and_container_id('Version', 1).last_journal) + assert events.include?(Attachment.find_by_container_type_and_container_id_and_id('Version', 1, 9).last_journal) assert_equal [Attachment], events.collect(&:journaled).collect(&:class).uniq assert_equal %w(Project Version), events.collect(&:journaled).collect(&:container_type).uniq.sort end