mirror of
https://github.com/GSA/notifications-api.git
synced 2026-08-23 07:46:06 -04:00
fix uuid
This commit is contained in:
@@ -599,7 +599,7 @@ def test_should_save_sms_template_to_and_persist_with_job_id(sample_job, mocker)
|
|||||||
assert persisted_notification.notification_type == NotificationType.SMS
|
assert persisted_notification.notification_type == NotificationType.SMS
|
||||||
|
|
||||||
provider_tasks.deliver_sms.apply_async.assert_called_once_with(
|
provider_tasks.deliver_sms.apply_async.assert_called_once_with(
|
||||||
[str(persisted_notification.id)], queue="send-sms-tasks"
|
[str(persisted_notification.id)], queue="send-sms-tasks", countdown=30
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
@@ -670,7 +670,7 @@ def test_should_use_email_template_and_persist(
|
|||||||
assert persisted_notification.notification_type == NotificationType.EMAIL
|
assert persisted_notification.notification_type == NotificationType.EMAIL
|
||||||
|
|
||||||
provider_tasks.deliver_email.apply_async.assert_called_once_with(
|
provider_tasks.deliver_email.apply_async.assert_called_once_with(
|
||||||
[str(persisted_notification.id)], queue="send-email-tasks"
|
[str(persisted_notification.id)], queue="send-email-tasks", countdown=30
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
@@ -707,7 +707,7 @@ def test_save_email_should_use_template_version_from_job_not_latest(
|
|||||||
assert not persisted_notification.sent_by
|
assert not persisted_notification.sent_by
|
||||||
assert persisted_notification.notification_type == NotificationType.EMAIL
|
assert persisted_notification.notification_type == NotificationType.EMAIL
|
||||||
provider_tasks.deliver_email.apply_async.assert_called_once_with(
|
provider_tasks.deliver_email.apply_async.assert_called_once_with(
|
||||||
[str(persisted_notification.id)], queue="send-email-tasks"
|
[str(persisted_notification.id)], queue="send-email-tasks", countdown=30
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
@@ -738,7 +738,7 @@ def test_should_use_email_template_subject_placeholders(
|
|||||||
assert not persisted_notification.reference
|
assert not persisted_notification.reference
|
||||||
assert persisted_notification.notification_type == NotificationType.EMAIL
|
assert persisted_notification.notification_type == NotificationType.EMAIL
|
||||||
provider_tasks.deliver_email.apply_async.assert_called_once_with(
|
provider_tasks.deliver_email.apply_async.assert_called_once_with(
|
||||||
[str(persisted_notification.id)], queue="send-email-tasks"
|
[str(persisted_notification.id)], queue="send-email-tasks", countdown=30
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
@@ -822,7 +822,7 @@ def test_should_use_email_template_and_persist_without_personalisation(
|
|||||||
assert not persisted_notification.reference
|
assert not persisted_notification.reference
|
||||||
assert persisted_notification.notification_type == NotificationType.EMAIL
|
assert persisted_notification.notification_type == NotificationType.EMAIL
|
||||||
provider_tasks.deliver_email.apply_async.assert_called_once_with(
|
provider_tasks.deliver_email.apply_async.assert_called_once_with(
|
||||||
[str(persisted_notification.id)], queue="send-email-tasks"
|
[str(persisted_notification.id)], queue="send-email-tasks", countdown=30
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -263,7 +263,7 @@ def test_send_notification_to_queue(
|
|||||||
|
|
||||||
send_notification_to_queue(notification=notification, queue=requested_queue)
|
send_notification_to_queue(notification=notification, queue=requested_queue)
|
||||||
|
|
||||||
mocked.assert_called_once_with([str(notification.id)], queue=expected_queue)
|
mocked.assert_called_once_with([str(notification.id)], queue=expected_queue, countdown=30)
|
||||||
|
|
||||||
|
|
||||||
def test_send_notification_to_queue_throws_exception_deletes_notification(
|
def test_send_notification_to_queue_throws_exception_deletes_notification(
|
||||||
@@ -278,6 +278,7 @@ def test_send_notification_to_queue_throws_exception_deletes_notification(
|
|||||||
mocked.assert_called_once_with(
|
mocked.assert_called_once_with(
|
||||||
[(str(sample_notification.id))],
|
[(str(sample_notification.id))],
|
||||||
queue="send-sms-tasks",
|
queue="send-sms-tasks",
|
||||||
|
countdown=30
|
||||||
)
|
)
|
||||||
|
|
||||||
assert _get_notification_query_count() == 0
|
assert _get_notification_query_count() == 0
|
||||||
|
|||||||
Reference in New Issue
Block a user