trabajo-afectivo/spec/models/ticket/enqueues_user_ticket_counter_job_examples.rb
2022-01-01 14:38:12 +01:00

12 lines
414 B
Ruby

# Copyright (C) 2012-2022 Zammad Foundation, https://zammad-foundation.org/
RSpec.shared_examples 'TicketEnqueuesTicketUserTicketCounterJob', type: :job do
subject { create(described_class.name.underscore) }
let(:customer) { create('customer') }
it 'enqueues a job for the customer' do
subject.customer = customer
expect { subject.save }.to have_enqueued_job(TicketUserTicketCounterJob)
end
end