Merge pull request #9569 from demarches-simplifiees/fix-email-service
fix: corrige l'envoi d'email aux admins avec service sans siret
This commit is contained in:
commit
2ed2125b2d
2 changed files with 2 additions and 2 deletions
|
@ -14,7 +14,7 @@ namespace :service do
|
|||
progress = ProgressReport.new(admins.count)
|
||||
|
||||
admins.each do |admin|
|
||||
AdministrateurMailer.notify_service_without_siret(admin.email).deliver
|
||||
AdministrateurMailer.notify_service_without_siret(admin.email).deliver_later
|
||||
progress.inc
|
||||
end
|
||||
end
|
||||
|
|
|
@ -36,7 +36,7 @@ describe 'service tasks' do
|
|||
|
||||
it 'emails admins with published procedures with services without siret' do
|
||||
message = double("message")
|
||||
allow(message).to receive(:deliver)
|
||||
allow(message).to receive(:deliver_later)
|
||||
allow(AdministrateurMailer).to receive(:notify_service_without_siret).with(administrateur.email).and_return(message)
|
||||
allow(AdministrateurMailer).to receive(:notify_service_without_siret).with(administrateur_with_siret_service.email).and_return(message)
|
||||
|
||||
|
|
Loading…
Reference in a new issue