Sha256: dccce5e89b2c7f082f7e370a2f07dd786be13306a1bd9e69e1336c5438986a28

Contents?: true

Size: 396 Bytes

Versions: 2

Compression:

Stored size: 396 Bytes

Contents

require 'database_cleaner'

RSpec.configure do |config|

  config.before(:suite) do
    DatabaseCleaner.clean_with :truncation
  end

  config.before do
    DatabaseCleaner.strategy = :transaction
  end

  config.before(:each, js: true) do
    DatabaseCleaner.strategy = :truncation
  end

  config.before do
    DatabaseCleaner.start
  end

  config.after do
    DatabaseCleaner.clean
  end
end

Version data entries

2 entries across 2 versions & 2 rubygems

Version Path
solidus_log_viewer-1.0.0 spec/support/database_cleaner.rb
solidus_papertrail-1.0.0 spec/support/database_cleaner.rb