Do not hard code test connection names in database cleaner

This commit is contained in:
Artur Beljajev 2017-04-10 19:18:36 +03:00
parent ede2710942
commit 66b7366ff2

View file

@ -1,5 +1,5 @@
RSpec.configure do |config|
db_connection_names = %i(test whois_test api_log_test registrant_write_test)
db_connection_names = ActiveRecord::Base.configurations.keys.grep(/test/).map(&:to_sym)
config.before :suite do
DatabaseCleaner.strategy = :truncation