<commit_before>require 'spec_helper'
require 'mongoid'
require 'mongoid-rspec'
include Mongoid::Matchers

# Load mongoid config
if Mongoid::VERSION < '3'
  ENV["MONGOID_ENV"] = "test"
  Mongoid.load!('./spec/groupify/mongoid2.yml')
  Mongoid.logger.level = :info
else
  Mongoid.load!('./spec/groupify/mongoid3.yml', :test)
end

require 'groupify'

class MongoidUser
  include Mongoid::Document
  
  acts_as_group_member :class_name => 'MongoidGroup'
  acts_as_named_group_member
end

class MongoidTask
  include Mongoid::Document
  
  acts_as_group_member :class_name => 'MongoidGroup'
end

class MongoidGroup
  include Mongoid::Document
  
  acts_as_group :members => [:mongoid_users, :mongoid_tasks], :default_members => :mongoid_users
  alias_method :users, :mongoid_users
end<commit_msg>Fixed Mongoid 2 logger in specs<commit_after>require 'spec_helper'
require 'mongoid'
require 'mongoid-rspec'
include Mongoid::Matchers

# Load mongoid config
if Mongoid::VERSION < '3'
  ENV["MONGOID_ENV"] = "test"
  Mongoid.load!('./spec/groupify/mongoid2.yml')
  Mongoid.logger.level = Logger::INFO
else
  Mongoid.load!('./spec/groupify/mongoid3.yml', :test)
end

require 'groupify'

class MongoidUser
  include Mongoid::Document
  
  acts_as_group_member :class_name => 'MongoidGroup'
  acts_as_named_group_member
end

class MongoidTask
  include Mongoid::Document
  
  acts_as_group_member :class_name => 'MongoidGroup'
end

class MongoidGroup
  include Mongoid::Document
  
  acts_as_group :members => [:mongoid_users, :mongoid_tasks], :default_members => :mongoid_users
  alias_method :users, :mongoid_users
end
{'fraction_non_alphanumeric': 0.1088985687616677, 'fraction_numerical': 0.0043559427504667085, 'mean_word_length': 5.756302521008403, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 11, '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': '4306889', 'n_tokens_mistral': 574, 'n_tokens_neox': 569, 'n_words': 116}