<commit_before>DatabaseCleaner[:active_record].strategy = :transaction if defined? ActiveRecord
DatabaseCleaner[:data_mapper].strategy = :transaction if defined? DataMapper
DatabaseCleaner[:mongoid].strategy = :truncation if defined? Mongoid
DatabaseCleaner[:mongo_mapper].strategy = :truncation if defined? MongoMapper

RSpec.configure do |config|
  config.before :suite do
    #DatabaseCleaner.clean_with :truncation

    DatabaseCleaner.clean_with :truncation if defined? ActiveRecord
    DatabaseCleaner.clean_with :transaction if defined? DataMapper
    DatabaseCleaner.clean_with :truncation if defined? Mongoid
    DatabaseCleaner.clean_with :truncation if defined? MongoMapper
  end
  config.before :each do
    DatabaseCleaner.start
  end
  config.after :each do
    DatabaseCleaner.clean
  end
end<commit_msg>Use truncation for DataMapper<commit_after>DatabaseCleaner[:active_record].strategy = :transaction if defined? ActiveRecord
DatabaseCleaner[:data_mapper].strategy = :truncation if defined? DataMapper
DatabaseCleaner[:mongoid].strategy = :truncation if defined? Mongoid
DatabaseCleaner[:mongo_mapper].strategy = :truncation if defined? MongoMapper

RSpec.configure do |config|
  config.before :suite do
    #DatabaseCleaner.clean_with :truncation

    DatabaseCleaner.clean_with :truncation if defined? ActiveRecord
    DatabaseCleaner.clean_with :truncation if defined? DataMapper
    DatabaseCleaner.clean_with :truncation if defined? Mongoid
    DatabaseCleaner.clean_with :truncation if defined? MongoMapper
  end
  config.before :each do
    DatabaseCleaner.start
  end
  config.after :each do
    DatabaseCleaner.clean
  end
end
{'fraction_non_alphanumeric': 0.06900726392251816, 'fraction_numerical': 0.0, 'mean_word_length': 5.774590163934426, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4902198', 'n_tokens_mistral': 480, 'n_tokens_neox': 458, 'n_words': 122}