- {% if notification.status|format_notification_status_as_url(notification.notification_type) %}
-
+ {% if notification.notification_type|format_notification_status_as_url %}
+
{% endif %}
{{ notification.status|format_notification_status(
notification.template.template_type
) }}
- {% if notification.status|format_notification_status_as_url(notification.notification_type) %}
+ {% if notification.notification_type|format_notification_status_as_url %}
{% endif %}
{% if sent_with_test_key %}
diff --git a/app/templates/views/message-status.html b/app/templates/views/message-status.html
index 26e168d90..3aed37fad 100644
--- a/app/templates/views/message-status.html
+++ b/app/templates/views/message-status.html
@@ -31,7 +31,7 @@
These are the types of message status you’ll see when you’re signed in to Notify.
If you’re using our API, some of the statuses you’ll see will be different. Read our documentation for a detailed list of API message statuses.
-
Emails
+
Emails
{% call mapping_table(
caption='Message statuses – emails',
@@ -54,7 +54,7 @@
{% endcall %}
-
Text messages
+
Text messages
{% call mapping_table(
caption='Message statuses – text messages',
@@ -77,7 +77,7 @@
{% endfor %}
{% endcall %}
-
+
Letters
{% call mapping_table(
diff --git a/tests/app/main/views/test_activity.py b/tests/app/main/views/test_activity.py
index 84106ff66..606ac5e7a 100644
--- a/tests/app/main/views/test_activity.py
+++ b/tests/app/main/views/test_activity.py
@@ -521,7 +521,10 @@ def test_html_contains_links_for_failed_notifications(
mock_get_service_data_retention,
mocker,
):
- mock_get_notifications(mocker, active_user_with_permissions, noti_status='technical-failure')
+ mock_get_notifications(mocker,
+ active_user_with_permissions,
+ diff_template_type="sms",
+ noti_status='technical-failure')
response = client_request.get(
'main.view_notifications',
service_id=SERVICE_ONE_ID,
diff --git a/tests/app/main/views/test_index.py b/tests/app/main/views/test_index.py
index 3d3088bd2..44e5dc411 100644
--- a/tests/app/main/views/test_index.py
+++ b/tests/app/main/views/test_index.py
@@ -114,6 +114,15 @@ def test_old_static_pages_redirect(
)
+def test_message_status_page_contains_message_status_ids(client_request):
+ # The 'email-statuses' and 'sms-statuses' id are linked to when we display a message status,
+ # so this test ensures we don't accidentally remove them
+ page = client_request.get('main.message_status')
+
+ assert page.find(id='email-statuses')
+ assert page.find(id='sms-statuses')
+
+
def test_old_using_notify_page(client_request):
client_request.get('main.using_notify', _expected_status=410)