File: spec_helper.rb

package info (click to toggle)
ruby-acts-as-api 1.0.1-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 624 kB
  • sloc: ruby: 2,366; makefile: 2
file content (16 lines) | stat: -rw-r--r-- 564 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
ENV['RAILS_ENV'] = 'test'

if ENV['ACTS_AS_API_ORM'] == 'active_record'
  require 'active_record_dummy/config/environment'

  load "#{Rails.root}/db/schema.rb" # use db agnostic schema by default
  # ActiveRecord::Migrator.up('db/migrate') # use migrations
elsif ENV['ACTS_AS_API_ORM'] == 'mongoid'
  require 'mongoid_dummy/config/environment'
end

require 'rspec/rails'

# Requires supporting ruby files with custom matchers and macros, etc,
# in spec/support/ and its subdirectories.
Dir[File.dirname(__FILE__) + '/support/**/*.rb'].each { |file| require file }