<commit_before>ENV["RAILS_ENV"] ||= "test"
require "spec_helper"
require File.expand_path("../../config/environment", __FILE__)
require "rspec/rails"
require "shoulda/matchers"

Dir[Rails.root.join("spec/support/**/*.rb")].each { |f| require f }

ActiveRecord::Migration.maintain_test_schema!

RSpec.configure do |config|
  config.infer_spec_type_from_file_location!

  config.include FactoryGirl::Syntax::Methods

  include Warden::Test::Helpers
  Warden.test_mode!
  config.before(:example, admin: true) do
    User.create!(name: "Admin", email: "<EMAIL>", admin: true, password: "<PASSWORD>")
  end
end<commit_msg>Fix hook<commit_after>ENV["RAILS_ENV"] ||= "test"
require "spec_helper"
require File.expand_path("../../config/environment", __FILE__)
require "rspec/rails"
require "shoulda/matchers"

Dir[Rails.root.join("spec/support/**/*.rb")].each { |f| require f }

ActiveRecord::Migration.maintain_test_schema!

RSpec.configure do |config|
  config.infer_spec_type_from_file_location!

  config.include FactoryGirl::Syntax::Methods

  include Warden::Test::Helpers
  Warden.test_mode!
  config.before(:example, admin: true) do
    User.create!(name: "Admin", email: "<EMAIL>", username: "admin", admin: true, password: "<PASSWORD>")
  end
end
{'fraction_non_alphanumeric': 0.16346153846153846, 'fraction_numerical': 0.0, 'mean_word_length': 6.096590909090909, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '2317575', 'n_tokens_mistral': 425, 'n_tokens_neox': 418, 'n_words': 80}