<commit_before>require 'rails_helper'

RSpec.describe Application, type: :model do
  subject { build(:application) }

  it_behaves_like 'HasSeason'

  it_behaves_like 'Rateable' do
    let(:application) { create(:application) }
  end

  describe 'associations' do
    it { is_expected.to belong_to(:team).inverse_of(:applications).counter_cache(true) }
    it { is_expected.to belong_to(:project) }
    it { is_expected.to belong_to(:application_draft) }
    it { is_expected.to belong_to(:application_draft) }
    it { is_expected.to have_many(:comments).dependent(:destroy).order(:created_at) }
  end

  describe 'validations' do
    it { is_expected.to validate_presence_of(:application_data) }
    it { is_expected.to validate_presence_of(:team) }<commit_msg>Document associations for application model<commit_after>require 'rails_helper'

RSpec.describe Application, type: :model do
  subject { build(:application) }

  it_behaves_like 'HasSeason'

  it_behaves_like 'Rateable' do
    let(:application) { create(:application) }
  end

  describe 'associations' do
    it { is_expected.to belong_to(:team).inverse_of(:applications).counter_cache(true) }
    it { is_expected.to belong_to(:project) }
    it { is_expected.to belong_to(:application_draft) }
    it { is_expected.to have_many(:comments).dependent(:destroy).order(:created_at) }
  end

  describe 'validations' do
    it { is_expected.to validate_presence_of(:application_data) }
    it { is_expected.to validate_presence_of(:team) }
{'fraction_non_alphanumeric': 0.112, 'fraction_numerical': 0.0, 'mean_word_length': 5.126530612244898, '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': '5426721', 'n_tokens_mistral': 491, 'n_tokens_neox': 470, 'n_words': 91}