Sha256: cf82e28536e592698df794787f4fb4c767b450497a0cb3cf49528b442d6fa814

Contents?: true

Size: 932 Bytes

Versions: 1

Compression:

Stored size: 932 Bytes

Contents

require 'rubygems'
require 'minitest/autorun'
require 'fileutils'
require 'active_record'
require 'logger'

# ------------------------------------------------------
# Setup AR environment
# ------------------------------------------------------

ActiveRecord::Base.establish_connection(
  {
    adapter:   "sqlite3",
    database: ":memory:",
  }
)

# Setup logger
tmp = File.expand_path('../../tmp', __FILE__)
FileUtils.mkdir_p(tmp)
ActiveRecord::Base.logger = Logger.new("#{tmp}/debug.log")

# I18n
I18n.load_path += Dir[File.expand_path('resources/locale/*.yml', File.dirname(__FILE__))]
I18n.default_locale = :en

puts :i18n_load => I18n.load_path

# ------------------------------------------------------
# Inject audit-trascer
#   and setup test schema
#   and define models used in tests
# ------------------------------------------------------
require "code-box"

require "resources/schema.rb"
require "resources/models.rb"

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
code-box-2.0.pre1 test/helper.rb