1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Change back occurrences of SQLite(3) to sqlite3 when referring to the

adapter, fixed from #16057 [ci skip]
This commit is contained in:
Zachary Scott 2014-07-06 11:47:16 -07:00
parent 2cda0aff30
commit 2f716694f2
5 changed files with 13 additions and 12 deletions

View file

@ -57,7 +57,7 @@ class ActiveRecordTestConnector
end
end
# Load actionpack SQLite tables
# Load actionpack sqlite3 tables
def load_schema
File.read(File.dirname(__FILE__) + "/fixtures/db_definitions/sqlite.sql").split(';').each do |sql|
ActiveRecord::Base.connection.execute(sql) unless sql.blank?

View file

@ -56,7 +56,7 @@ module ActiveRecord
# This works for mysql and mysql2 where table.column can be used to
# resolve ambiguity.
#
# We override this in the SQLite and PostgreSQL adapters to use only
# We override this in the sqlite3 and postgresql adapters to use only
# the column name (as per syntax requirements).
def quote_table_name_for_assignment(table, attr)
quote_table_name("#{table}.#{attr}")

View file

@ -7,16 +7,16 @@ require 'sqlite3'
module ActiveRecord
module ConnectionHandling # :nodoc:
# SQLite3 adapter reuses sqlite_connection.
# sqlite3 adapter reuses sqlite_connection.
def sqlite3_connection(config)
# Require database.
unless config[:database]
raise ArgumentError, "No database file specified. Missing argument: database"
end
# Allow database path relative to Rails.root, but only if
# the database path is not the special path that tells
# SQLite to build a database only in memory.
# Allow database path relative to Rails.root, but only if the database
# path is not the special path that tells sqlite to build a database only
# in memory.
if ':memory:' != config[:database]
config[:database] = File.expand_path(config[:database], Rails.root) if defined?(Rails.root)
dirname = File.dirname(config[:database])

View file

@ -57,10 +57,11 @@ module ActiveRecord
end
end
# SQLite databases should be able to support any type and not
# just the ones mentioned in the native_database_types.
# Therefore test_invalid column should always return true
# even if the type is not valid.
# sqlite3 databases should be able to support any type and not just the
# ones mentioned in the native_database_types.
#
# Therefore test_invalid column should always return true even if the
# type is not valid.
def test_invalid_column
assert @conn.valid_type?(:foobar)
end
@ -126,7 +127,7 @@ module ActiveRecord
assert @conn, 'should have connection'
end
# SQLite3 defaults to UTF-8 encoding
# sqlite3 defaults to UTF-8 encoding
def test_encoding
assert_equal 'UTF-8', @conn.encoding
end

View file

@ -48,7 +48,7 @@
*Matthew Draper*
* Remove SQLite3 lines from `.gitignore` if the application is not using SQLite3.
* Remove sqlite3 lines from `.gitignore` if the application is not using sqlite3.
*Dmitrii Golub*