]> nos-oignons.net Git - gestion-adh.git/blobdiff - features/step_definitions/emails.rb
Only send reminders when the time has really come
[gestion-adh.git] / features / step_definitions / emails.rb
index 2bbecd33a1583d23dccac6b9b0b3bb57a805a5cf..e2e562e2bf46c7afa2a17238cd4057aa12ce944d 100644 (file)
@@ -28,6 +28,14 @@ Then /^(\d+) emails? (?:doit|doivent) avoir été envoyés?$/ do |count|
   Mail::TestMailer.deliveries.should have(count).email
 end
 
+Then /^des emails doivent avoir été envoyés à Jane, Fatima, Fred et Moly$/ do
+  recipients = Mail::TestMailer.deliveries.collect(&:to)
+  recipients.should include(['jane@example.org'])
+  recipients.should include(['fatima@example.org'])
+  recipients.should include(['fred@example.org'])
+  recipients.should include(['moly@example.org'])
+end
+
 Then /^un email doit avoir été envoyé au comité de déontologie$/ do
   expect(Mail::TestMailer.deliveries).to have(1).email
   expect(Mail::TestMailer.deliveries.first.to).to include('deontologie@nos-oignons.net')