Use sqlite in-memory DB in specs
https://www.sqlite.org/inmemorydb.html
This commit is contained in:
parent
ca810767e7
commit
05bf5a3713
|
@ -1,6 +1,6 @@
|
||||||
ActiveRecord::Base.establish_connection(
|
ActiveRecord::Base.establish_connection(
|
||||||
adapter: "sqlite3",
|
adapter: "sqlite3",
|
||||||
database: File.join(File.dirname(__FILE__), "test.db"),
|
database: ":memory:",
|
||||||
)
|
)
|
||||||
|
|
||||||
migration_class =
|
migration_class =
|
||||||
|
|
|
@ -57,7 +57,7 @@ RSpec.configure do |config|
|
||||||
config.before(:all) do
|
config.before(:all) do
|
||||||
ActiveRecord::Base.establish_connection(
|
ActiveRecord::Base.establish_connection(
|
||||||
adapter: "sqlite3",
|
adapter: "sqlite3",
|
||||||
database: File.join(File.dirname(__FILE__), "test.db"),
|
database: ":memory:",
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue