Sha256: 85d2e020e0fb18c90057f44dbcb0af833abc92a670cf6215aee90df2fda0bc65

Contents?: true

Size: 738 Bytes

Versions: 3

Compression:

Stored size: 738 Bytes

Contents

require 'rspec'

require 'mongoid'
require 'mongoscript'

RSpec.configure do |config|
  config.mock_with :mocha
  config.treat_symbols_as_metadata_keys_with_true_values = true
  config.run_all_when_everything_filtered = true

  config.before :each do
    database_adapter = stub("MongoDB database")
    database_adapter.stubs(:command).returns({"ok" => 1.0})
    MongoScript.stubs(:database).returns(database_adapter)
  end
end

Dir[File.join(File.dirname(__FILE__), "support", "**", "*.rb")].each {|f| load f}

SCRIPTS_PATH = File.join(File.dirname(__FILE__), "fixtures")

# Integration testing
# Mongoid requires a RAILS_ENV to be set
ENV["RACK_ENV"] ||= "test"
Mongoid.load!(File.join(File.dirname(__FILE__), "support", "mongoid.yml"))

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
mongoscript-0.0.10 spec/spec_helper.rb
mongoscript-0.0.9 spec/spec_helper.rb
mongoscript-0.0.8 spec/spec_helper.rb