diff options
author | Andrey Deryabin <deriabin@gmail.com> | 2012-04-27 13:31:37 +0700 |
---|---|---|
committer | Andrey Deryabin <deriabin@gmail.com> | 2012-04-27 13:31:37 +0700 |
commit | d42b60a411c09dd9b69942dabbcdba6a05f259e8 (patch) | |
tree | a0bc00e72d3a29aabc99d3e350d438e16fad4f50 | |
parent | dd05a49a4aa037ed2dc95339c5e0c8eab75f862e (diff) | |
download | rails-d42b60a411c09dd9b69942dabbcdba6a05f259e8.tar.gz rails-d42b60a411c09dd9b69942dabbcdba6a05f259e8.tar.bz2 rails-d42b60a411c09dd9b69942dabbcdba6a05f259e8.zip |
fix tests for SQLite3Adapter
-rw-r--r-- | activerecord/lib/active_record/validations/uniqueness.rb | 1 | ||||
-rw-r--r-- | activerecord/test/cases/adapters/sqlite3/quoting_test.rb | 2 | ||||
-rw-r--r-- | activerecord/test/cases/base_test.rb | 2 | ||||
-rw-r--r-- | activerecord/test/cases/helper.rb | 2 |
4 files changed, 3 insertions, 4 deletions
diff --git a/activerecord/lib/active_record/validations/uniqueness.rb b/activerecord/lib/active_record/validations/uniqueness.rb index db618f617f..9e4b588ac2 100644 --- a/activerecord/lib/active_record/validations/uniqueness.rb +++ b/activerecord/lib/active_record/validations/uniqueness.rb @@ -196,7 +196,6 @@ module ActiveRecord # The following bundled adapters throw the ActiveRecord::RecordNotUnique exception: # * ActiveRecord::ConnectionAdapters::MysqlAdapter # * ActiveRecord::ConnectionAdapters::Mysql2Adapter - # * ActiveRecord::ConnectionAdapters::SQLiteAdapter # * ActiveRecord::ConnectionAdapters::SQLite3Adapter # * ActiveRecord::ConnectionAdapters::PostgreSQLAdapter # diff --git a/activerecord/test/cases/adapters/sqlite3/quoting_test.rb b/activerecord/test/cases/adapters/sqlite3/quoting_test.rb index 1dbeb66af6..2ba9143cd5 100644 --- a/activerecord/test/cases/adapters/sqlite3/quoting_test.rb +++ b/activerecord/test/cases/adapters/sqlite3/quoting_test.rb @@ -5,7 +5,7 @@ require 'securerandom' module ActiveRecord module ConnectionAdapters - class SQLiteAdapter + class SQLite3Adapter class QuotingTest < ActiveRecord::TestCase def setup @conn = Base.sqlite3_connection :database => ':memory:', diff --git a/activerecord/test/cases/base_test.rb b/activerecord/test/cases/base_test.rb index da7d99e2c5..19ef2f592d 100644 --- a/activerecord/test/cases/base_test.rb +++ b/activerecord/test/cases/base_test.rb @@ -228,7 +228,7 @@ class BasicsTest < ActiveRecord::TestCase ) # For adapters which support microsecond resolution. - if current_adapter?(:PostgreSQLAdapter) || current_adapter?(:SQLiteAdapter) + if current_adapter?(:PostgreSQLAdapter) || current_adapter?(:SQLite3Adapter) assert_equal 11, Topic.find(1).written_on.sec assert_equal 223300, Topic.find(1).written_on.usec assert_equal 9900, Topic.find(2).written_on.usec diff --git a/activerecord/test/cases/helper.rb b/activerecord/test/cases/helper.rb index 5c3560a33b..345ae0b582 100644 --- a/activerecord/test/cases/helper.rb +++ b/activerecord/test/cases/helper.rb @@ -36,7 +36,7 @@ def current_adapter?(*types) end def in_memory_db? - current_adapter?(:SQLiteAdapter) && + current_adapter?(:SQLite3Adapter) && ActiveRecord::Base.connection_pool.spec.config[:database] == ":memory:" end |