Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

fixed test_batch_notifications()

  • Loading branch information...
commit af7c75dd1b5ce5ec7202a89ddace984d2737a14b 1 parent 56db8f7
@swarbhanu swarbhanu authored
View
2  ion/services/dm/presentation/test/user_notification_test.py
@@ -1397,7 +1397,7 @@ def cleanup_timer(scheduler, schedule_id):
ar_1 = gevent.event.AsyncResult()
ar_2 = gevent.event.AsyncResult()
- def send_email(events_for_message, user_id):
+ def send_email(events_for_message, user_id, *args, **kwargs):
log.warning("(in asyncresult) events_for_message: %s" % events_for_message)
ar_1.set(events_for_message)
ar_2.set(user_id)
View
6 ion/services/dm/presentation/user_notification_service.py
@@ -705,7 +705,9 @@ def process_batch(self, start_time = 0, end_time = 0):
# send a notification email to each user using a _send_email() method
if events_for_message:
- self.format_and_send_email(events_for_message, user_id, self.smtp_client)
+ self.format_and_send_email(events_for_message = events_for_message,
+ user_id = user_id,
+ smtp_client=self.smtp_client)
self.smtp_client.quit()
@@ -756,7 +758,7 @@ def format_and_send_email(self, events_for_message = None, user_id = None, smtp_
smtp_client=smtp_client )
- def send_batch_email(self, msg_body, msg_subject, msg_recipient, smtp_client):
+ def send_batch_email(self, msg_body = None, msg_subject = None, msg_recipient = None, smtp_client = None):
"""
Send the email
Please sign in to comment.
Something went wrong with that request. Please try again.