Sha256: 6823d9c0692d021dd434bd076a0bb72031286e52ba5746d1ef9ea7d1f9d42592

Contents?: true

Size: 1.07 KB

Versions: 23

Compression:

Stored size: 1.07 KB

Contents

# Configure Rails Environment
ENV["RAILS_ENV"] ||= "test"

# What will our dummy Rails app be?
require File.expand_path("../dummy/config/environment.rb",  __FILE__)

require 'rspec/rails'
require 'rspec/autorun'
require 'factory_girl'

ENGINE_RAILS_ROOT = File.join(File.dirname(__FILE__), '../')

# Require supporting files in spec/support
Dir[File.join(ENGINE_RAILS_ROOT, "spec/support/**/*.rb")].each {|f| require f }

RSpec.configure do |config|
  config.use_transactional_fixtures = true
  config.include Naf::Engine.routes.url_helpers
  config.infer_base_class_for_anonymous_controllers = true
  config.include EngineRouting, type: :controller
end

FactoryGirl.find_definitions

# Create the DB Seed Records via Factories
affinities = [:normal_affinity, :canary_affinity, :perennial_affinity]
classifications = [:location_affinity_classification, :purpose_affinity_classification, :application_affinity_classification]
restrictions = [:no_limit, :limited_per_machine, :limited_per_all_machines]

(affinities + classifications + restrictions).each do |seed|
  FactoryGirl.create(seed)
end

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
naf-2.1.13 spec/spec_helper.rb
naf-2.1.12 spec/spec_helper.rb
naf-2.1.11 spec/spec_helper.rb
naf-2.1.10 spec/spec_helper.rb
naf-2.1.9 spec/spec_helper.rb
naf-2.1.8 spec/spec_helper.rb
naf-2.1.6 spec/spec_helper.rb
naf-2.1.5 spec/spec_helper.rb
naf-2.1.4 spec/spec_helper.rb
naf-2.1.3 spec/spec_helper.rb
naf-2.1.2 spec/spec_helper.rb
naf-2.1.1 spec/spec_helper.rb
naf-2.1.0 spec/spec_helper.rb
naf-2.0.4 spec/spec_helper.rb
naf-2.0.3 spec/spec_helper.rb
naf-2.0.2 spec/spec_helper.rb
naf-2.0.1 spec/spec_helper.rb
naf-2.0.0 spec/spec_helper.rb
naf-1.1.4 spec/spec_helper.rb
naf-1.1.3 spec/spec_helper.rb