<commit_before>class Skill < ActiveRecord::Base
  has_many :proficiencies
  has_many :users, through: :proficiencies

  before_validation :downcase_name

  validates :skill_name, presence: true, uniqueness: { case_sensitive: false }


  def downcase_name
    unless self.skill_name.nil?
      self.skill_name.downcase!
    end
  end

end<commit_msg>ADDED Apprenticeship rspec and validations, CHANGED database Apprenticeship and Rating timestamps to refuse NULL values<commit_after>class Skill < ActiveRecord::Base
  has_many :proficiencies
  has_many :users, through: :proficiencies

  before_validation :downcase_name

  validates :skill_name, presence: true, uniqueness: { case_sensitive: false }


  def downcase_name
    self.skill_name.to_s.downcase!
  end

end
{'fraction_non_alphanumeric': 0.06649282920469361, 'fraction_numerical': 0.0, 'mean_word_length': 5.047244094488189, 'pattern_counts': {'":': 0, '<': 5, '<?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': '4183362', 'n_tokens_mistral': 249, 'n_tokens_neox': 241, 'n_words': 62}