From 2ce57fd0d9e2c1c1f787a0874f5292d5b2e9e539 Mon Sep 17 00:00:00 2001 From: Emilio Tagua Date: Wed, 1 Sep 2010 10:04:33 -0300 Subject: [PATCH] Fix test: this should return 0 not 7, since Arel was ignoring select clause and now it's fixed. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: José Valim --- activerecord/test/cases/relations_test.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/activerecord/test/cases/relations_test.rb b/activerecord/test/cases/relations_test.rb index aa75aa27d4cb7..be038bfa74c50 100644 --- a/activerecord/test/cases/relations_test.rb +++ b/activerecord/test/cases/relations_test.rb @@ -521,7 +521,7 @@ def test_count_explicit_columns posts = Post.scoped assert_equal [0], posts.select('comments_count').where('id is not null').group('id').order('id').count.values.uniq - assert_equal 7, posts.where('id is not null').select('comments_count').count + assert_equal 0, posts.where('id is not null').select('comments_count').count assert_equal 7, posts.select('comments_count').count('id') assert_equal 0, posts.select('comments_count').count