Merge pull request #10883 from colinux/helpscout-instructeur-notif

ETQ support je vois dans HS lorsqu'un instructeur a désactivé ses notifications
This commit is contained in:
Colin Darie 2024-10-03 09:12:15 +00:00 committed by GitHub
commit 3923e316e1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 26 additions and 0 deletions

View file

@ -63,6 +63,20 @@ describe WebhookController, type: :controller do
it 'returns a link to the Administrateur profile in the Manager' do
expect(payload).to have_key('html')
expect(payload['html']).to have_selector("a[href='#{manager_administrateur_url(admin)}']")
expect(payload['html']).to have_text("Notifications activées")
end
end
context "when notifications are disabled" do
let(:instructeur) { create(:instructeur, user:) }
let(:procedure) { create(:procedure) }
before do
create(:assign_to, instructeur:, procedure:,
instant_email_dossier_notifications_enabled: false)
end
it 'returns a summary of disabled notifications' do
expect(payload['html']).to have_text("Notifs désactivées Procedure##{procedure.id}")
end
end
end