Sha256: 4a68f34b8a4bef94fd348f9e12c450b4c1726c1e294520ce3a683bfedc063a7e

Contents?: true

Size: 326 Bytes

Versions: 2

Compression:

Stored size: 326 Bytes

Contents

require 'database_cleaner'

RSpec.configure do |config|
  config.before(:suite) do
    DatabaseCleaner[:mongoid].strategy = :truncation
    DatabaseCleaner.clean_with(:truncation)
  end

  config.before(:each) do
    DatabaseCleaner[:mongoid].start
  end

  config.after(:each) do
    DatabaseCleaner[:mongoid].clean
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
mongoid-sortable-1.0.0 spec/support/mongoid.rb
mongoid-sortable-0.0.1 spec/support/mongoid.rb