Skip to content

Commit

Permalink
squash 2286
Browse files Browse the repository at this point in the history
  • Loading branch information
kalbfled committed Feb 6, 2025
1 parent 6ef39f3 commit ad52588
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/app/celery/test_tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -531,6 +531,7 @@ def test_should_put_save_sms_task_in_research_mode_queue_if_research_mode_servic
assert mocked_deliver_sms.called


@pytest.mark.serial
def test_should_save_sms_if_restricted_service_and_valid_number(
notify_db_session,
mocker,
Expand All @@ -547,6 +548,8 @@ def test_should_save_sms_if_restricted_service_and_valid_number(
encrypt_notification = encryption.encrypt(notification)
notification_id = uuid4()

mocker.patch('app.celery.provider_tasks.deliver_sms.apply_async')

save_sms(
service.id,
notification_id,
Expand All @@ -566,8 +569,6 @@ def test_should_save_sms_if_restricted_service_and_valid_number(
assert not persisted_notification.personalisation
assert persisted_notification.notification_type == SMS_TYPE

mocker.patch('app.celery.provider_tasks.deliver_sms.apply_async')

provider_tasks.deliver_sms.apply_async.assert_called_once_with(
args=(),
kwargs={'notification_id': str(persisted_notification.id)},
Expand Down

0 comments on commit ad52588

Please sign in to comment.