<commit_before>$LOAD_PATH.unshift(File.dirname(__FILE__))
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), "lib"))
MODELS = File.join(File.dirname(__FILE__), "models")
$LOAD_PATH.unshift(MODELS)
VALIDATORS = File.join(File.dirname(__FILE__), "validators")
$LOAD_PATH.unshift(VALIDATORS)

require "rubygems"
require "bundler"
Bundler.setup

require 'mongoid'
require 'rspec'
require 'rspec/core'
require 'rspec/expectations'

Mongoid.configure do |config|
  config.connect_to("mongoid-rspec-test")
end

Dir[ File.join(MODELS, "*.rb") ].sort.each { |file| require File.basename(file) }

require 'mongoid-rspec'

RSpec.configure do |config|
  config.include RSpec::Matchers<commit_msg>Update RSpec configuration. Set mongoid log level to debug in order to prevent poluting RSpec's output<commit_after>$LOAD_PATH.unshift(File.dirname(__FILE__))
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), "lib"))
MODELS = File.join(File.dirname(__FILE__), "models")
$LOAD_PATH.unshift(MODELS)
VALIDATORS = File.join(File.dirname(__FILE__), "validators")
$LOAD_PATH.unshift(VALIDATORS)

require "rubygems"
require "bundler"
Bundler.setup

require 'mongoid'
require 'rspec'
require 'rspec/core'
require 'rspec/expectations'

Mongoid::Config.connect_to('mongoid-rspec-test')
Mongo::Logger.logger.level = ::Logger::INFO

Dir[ File.join(MODELS, "*.rb") ].sort.each { |file| require File.basename(file) }

require 'mongoid-rspec'

RSpec.configure do |config|
  config.include RSpec::Matchers
{'fraction_non_alphanumeric': 0.14749661705006767, 'fraction_numerical': 0.0, 'mean_word_length': 7.262569832402234, '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': '7206502', 'n_tokens_mistral': 531, 'n_tokens_neox': 526, 'n_words': 98}