describe Book, type: :model do
  describe "associations" do
    it { is_expected.to have_many(:transactions).dependent(:destroy) }
  end

  describe "validations" do
    it { is_expected.to validate_presence_of(:author) }
    it { is_expected.to validate_presence_of(:title) }
  end
end
