require 'rails_helper'

RSpec.describe School, type: :model do
  subject { build(:school) }

  it { is_expected.to be_valid }

  describe 'associations' do
    it { should have_many(:accounting_categories) }
    it { should have_many(:accounting_subcategories).through(:accounting_categories) }

    it { should have_many(:discipline_groups) }
    it { should have_many(:discipline_violations) }

    it { should have_many(:library_bibs) }
    it { should have_many(:library_item_conditions) }
    it { should have_many(:library_item_types) }
    it { should have_many(:library_locations) }

    it { should have_one(:school_branding) }

    it { should have_many(:service_groups) }
    it { should have_many(:service_opportunities) }
    it { should have_one(:service_requirement) }

    it { should have_many(:users) }
  end
end
