chore(job): DossierIndexSearchTerms in low_priority queue

This commit is contained in:
Colin Darie 2024-05-23 19:09:04 +02:00
parent 2c07f0260c
commit eaf9773e9e
No known key found for this signature in database
GPG key ID: 4FB865FDBCA4BCC4
2 changed files with 3 additions and 1 deletions

View file

@ -1,4 +1,6 @@
class DossierIndexSearchTermsJob < ApplicationJob
queue_as :low_priority
discard_on ActiveRecord::RecordNotFound
def perform(dossier)

View file

@ -12,7 +12,7 @@ RSpec.describe InstructeurMailer, type: :mailer do
before { ENV['BULK_EMAIL_QUEUE'] = custom_queue }
it 'enqueues email is custom queue for low priority delivery' do
expect { subject.deliver_later }.to have_enqueued_job.on_queue(custom_queue)
expect { subject.deliver_later }.to have_enqueued_job(PriorizedMailDeliveryJob).on_queue(custom_queue)
end
end
end