Sha256: fc1e1d994cb5b5c5b21d59879a2e6d2d4b0c9caf4c30126da7596dda4e1aa453

Contents?: true

Size: 730 Bytes

Versions: 3

Compression:

Stored size: 730 Bytes

Contents

begin
  # Try to require the preresolved locked set of gems.
  require File.expand_path('../../.bundle/environment', __FILE__)
rescue LoadError
  # Fall back on doing an unlocked resolve at runtime.
  require "rubygems"
  require "bundler"
  Bundler.setup
end

require 'spec'

# Require MongoModel library
require File.dirname(__FILE__) + '/../lib/mongomodel'

# Require spec helpers
Dir[File.dirname(__FILE__) + "/support/**/*.rb"].each { |f| require f }

Spec::Runner.configure do |config|
  include SpecsFor
  include DefineClass
  
  config.before(:all) do
    MongoModel.configuration = { 'database' => 'mongomodel-specs' }
  end
  
  config.before(:each) do
    MongoModel.database.collections.each { |c| c.drop }
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
mongomodel-0.2.1 spec/spec_helper.rb
mongomodel-0.2.0 spec/spec_helper.rb
mongomodel-0.1.6 spec/spec_helper.rb