Add first pass coverage for `AnnualReport` class (#31704)

pull/31499/head
Matt Jankowski 2024-09-03 05:05:26 -04:00 committed by GitHub
parent 2a244e2fdb
commit 31c00108a4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 16 additions and 0 deletions

View File

@ -0,0 +1,16 @@
# frozen_string_literal: true
require 'rails_helper'
describe AnnualReport do
describe '#generate' do
subject { described_class.new(account, Time.zone.now.year) }
let(:account) { Fabricate :account }
it 'builds a report for an account' do
expect { subject.generate }
.to change(GeneratedAnnualReport, :count).by(1)
end
end
end