<commit_before>
if ENV['run_with_real_active_record']
  Bundler.require(:test)
  require "active_record"
else
  if RUBY_ENGINE == "opal"
    require 'opal-rspec'
    require 'opal-activerecord'
  else
    require_relative '../opal/active_record/core'
  end
end


module TestUnitHelpers
  def assert_equal actual, expected
    actual.should == expected
  end
end

RSpec.configure do |config|
  config.include TestUnitHelpers
end

def running_with_real_active_record
  ENV['run_with_real_active_record']
end

<commit_msg>Allowed this to run with PhantomJS (but now running with actual active record needs to uncomment some lines).<commit_after>
if ENV['run_with_real_active_record']
  #Bundler.require(:test)
  #require "active_record"
else
  if RUBY_ENGINE == "opal"
    require 'opal-rspec'
    require 'opal-activerecord'
  else
    require_relative '../opal/active_record/core'
  end
end


module TestUnitHelpers
  def assert_equal actual, expected
    actual.should == expected
  end
end

RSpec.configure do |config|
  config.include TestUnitHelpers
end

def running_with_real_active_record
  ENV['run_with_real_active_record']
end


{'fraction_non_alphanumeric': 0.07834507042253522, 'fraction_numerical': 0.0, 'mean_word_length': 4.656716417910448, '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': '4184521', 'n_tokens_mistral': 389, 'n_tokens_neox': 372, 'n_words': 95}