Sha256: 202f2a60aa58f395a103ee84af20b8527ee4f5176595936f3e9452b0a587ca96
Contents?: true
Size: 528 Bytes
Versions: 13
Compression:
Stored size: 528 Bytes
Contents
$LOAD_PATH.unshift File.expand_path('..', __dir__) ENV['RACK_ENV'] = 'test' require 'active_record' require 'database_cleaner' require 'slack-ruby-bot-server/rspec' db_config = YAML.safe_load(File.read(File.expand_path('../config/postgresql.yml', __dir__)), [], [], true)[ENV['RACK_ENV']] ActiveRecord::Tasks::DatabaseTasks.create(db_config) ActiveRecord::Base.establish_connection(db_config) RSpec.configure do |config| config.around :each do |example| DatabaseCleaner.cleaning do example.run end end end
Version data entries
13 entries across 13 versions & 1 rubygems