From 25e5b0c4a8d0045715a6ad11e2898585826e4e9b Mon Sep 17 00:00:00 2001 From: Pratik Naik Date: Mon, 17 Aug 2009 13:56:59 +0100 Subject: Remove support for SQLite 2. If you're still using it, please install the plugin from git://github.com/rails/sqlite2_adapter.git --- activerecord/test/cases/base_test.rb | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) (limited to 'activerecord/test/cases') diff --git a/activerecord/test/cases/base_test.rb b/activerecord/test/cases/base_test.rb index 88738d90b1..8421a8fb07 100755 --- a/activerecord/test/cases/base_test.rb +++ b/activerecord/test/cases/base_test.rb @@ -1775,17 +1775,15 @@ class BasicsTest < ActiveRecord::TestCase assert_equal res4, res5 - unless current_adapter?(:SQLite2Adapter, :DeprecatedSQLiteAdapter) - res6 = Post.count_by_sql "SELECT COUNT(DISTINCT p.id) FROM posts p, comments co WHERE p.#{QUOTED_TYPE} = 'Post' AND p.id=co.post_id" - res7 = nil - assert_nothing_raised do - res7 = Post.count(:conditions => "p.#{QUOTED_TYPE} = 'Post' AND p.id=co.post_id", - :joins => "p, comments co", - :select => "p.id", - :distinct => true) - end - assert_equal res6, res7 + res6 = Post.count_by_sql "SELECT COUNT(DISTINCT p.id) FROM posts p, comments co WHERE p.#{QUOTED_TYPE} = 'Post' AND p.id=co.post_id" + res7 = nil + assert_nothing_raised do + res7 = Post.count(:conditions => "p.#{QUOTED_TYPE} = 'Post' AND p.id=co.post_id", + :joins => "p, comments co", + :select => "p.id", + :distinct => true) end + assert_equal res6, res7 end def test_clear_association_cache_stored -- cgit v1.2.3