Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
whabanks committed Feb 18, 2025
1 parent 59d5014 commit 0509e9b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion app/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -1905,7 +1905,7 @@ def _get_sms_status_by_feedback_reason():
"technical-failure": "Tech issue",
"temporary-failure": "Carrier issue",
"permanent-failure": "No such number",
"pinpoint-failure": _get_sms_status_by_feedback_reason(),
"provider-failure": _get_sms_status_by_feedback_reason(),
"delivered": "Delivered",
"sending": "In transit",
"created": "In transit",
Expand Down
8 changes: 4 additions & 4 deletions tests/app/dao/notification_dao/test_notification_dao.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,15 +135,15 @@ def test_should_update_feedback_reason_if_present(sample_template, sample_job):

with freeze_time("2000-01-02 12:00:00"):
updated = update_notification_status_by_id(
notification.id, status="pinpoint-failure", feedback_reason="NO_ORIGINATION_IDENTITIES_FOUND"
notification.id, status="provider-failure", feedback_reason="NO_ORIGINATION_IDENTITIES_FOUND"
)

assert updated.status == "pinpoint-failure"
assert updated.status == "provider-failure"
assert updated.updated_at == datetime(2000, 1, 2, 12, 0, 0)
assert updated.feedback_reason == "NO_ORIGINATION_IDENTITIES_FOUND"
assert Notification.query.get(notification.id).status == "pinpoint-failure"
assert Notification.query.get(notification.id).status == "provider-failure"
assert notification.updated_at == datetime(2000, 1, 2, 12, 0, 0)
assert notification.status == "pinpoint-failure"
assert notification.status == "provider-failure"
assert notification.feedback_reason == "NO_ORIGINATION_IDENTITIES_FOUND"


Expand Down

0 comments on commit 0509e9b

Please sign in to comment.