Sha256: e223ba59c5f8f105d16d29fd85abbd517cdc0d9a1c3a98226bbd4802aad3d103

Contents?: true

Size: 510 Bytes

Versions: 8

Compression:

Stored size: 510 Bytes

Contents

require 'database_cleaner'

RSpec.configure do |config|
  config.before(:suite) do
    DatabaseCleaner.clean_with(:truncation,
      except: %w[spatial_ref_sys schema_migrations]
    )
  end

  config.before(:each) { DatabaseCleaner.strategy = :truncation }

  config.before(:each, js: true) do
    DatabaseCleaner.strategy = :truncation,
      { except: %w[spatial_ref_sys schema_migrations] }
  end

  config.before(:each) { DatabaseCleaner.start }
  config.append_after(:each) { DatabaseCleaner.clean }
end

Version data entries

8 entries across 8 versions & 2 rubygems

Version Path
hertz-2.0.0 spec/support/database_cleaner.rb
hertz-1.0.2 spec/support/database_cleaner.rb
timeful-2.1.0 spec/support/database_cleaner.rb
timeful-2.0.0 spec/support/database_cleaner.rb
timeful-1.1.0 spec/support/database_cleaner.rb
timeful-1.0.0 spec/support/database_cleaner.rb
timeful-0.0.1 spec/support/database_cleaner.rb
hertz-1.0.1 spec/support/database_cleaner.rb