1
0
Fork 0
mirror of https://github.com/kaminari/kaminari.git synced 2022-11-09 13:44:37 -05:00

Let the RDBMS specifiable via envvar

This commit is contained in:
Akira Matsuda 2017-06-02 19:23:37 +09:00
parent b6c662950f
commit 48c0d14b2b
2 changed files with 5 additions and 1 deletions

View file

@ -1,5 +1,8 @@
test:
sqlite3: &sqlite3
adapter: sqlite3
database: kaminari_test.sqlite3
pool: 5
timeout: 5000
test:
<<: *<%= ENV['DB'] %>

View file

@ -4,6 +4,7 @@ $LOAD_PATH.unshift(File.join(Gem.loaded_specs['kaminari-core'].gem_dir, 'test'))
$LOAD_PATH.unshift(File.dirname(__FILE__))
ENV['RAILS_ENV'] ||= 'test'
ENV['DB'] ||= 'sqlite3'
require 'rails'
require 'active_record'