diff --git a/engine/apps/slack/scenarios/paging.py b/engine/apps/slack/scenarios/paging.py index f831510db..7d18cee87 100644 --- a/engine/apps/slack/scenarios/paging.py +++ b/engine/apps/slack/scenarios/paging.py @@ -840,24 +840,26 @@ def _get_team_select_blocks( blocks.extend( [ + team_severity_checkboxes_element, typing.cast( Block.Context, { + # NOTE: we add this here instead of as a checkbox option description because those can only + # be defined as plain text (ie. not markdown where links are supported) "type": "context", "elements": [ { "type": "mrkdwn", "text": ( - "Check the following box if you would like to escalate to this team as an 'important' " - "escalation. This will set a `payload.oncall.important` attribute in the alert to `true`. " - "Teams can configure their Direct Paging Integration to route to different escalation chains " - "based on this. " + "Check the above box if you would like to escalate to this team as an 'important' " + "escalation. Teams can configure their Direct Paging Integration to route to different " + "escalation chains based on this. " + "" ), }, ], }, ), - team_severity_checkboxes_element, ] ) diff --git a/engine/apps/slack/tests/scenario_steps/test_paging.py b/engine/apps/slack/tests/scenario_steps/test_paging.py index ec852150a..e0800ee28 100644 --- a/engine/apps/slack/tests/scenario_steps/test_paging.py +++ b/engine/apps/slack/tests/scenario_steps/test_paging.py @@ -539,7 +539,7 @@ def _setup_direct_paging_integration(team): ) assert len(blocks) == 4 - input_block, context_block, team_severity_context_block, team_severity_checkboxes = blocks + input_block, context_block, team_severity_checkboxes, team_severity_context_block = blocks team_severity_important_checkbox_option = { "text": { @@ -566,10 +566,10 @@ def _sort_team_options(options): ) assert team_severity_context_block["elements"][0]["text"] == ( - "Check the following box if you would like to escalate to this team as an 'important' " - "escalation. This will set a `payload.oncall.important` attribute in the alert to `true`. " - "Teams can configure their Direct Paging Integration to route to different escalation chains " - "based on this. " + "Check the above box if you would like to escalate to this team as an 'important' " + "escalation. Teams can configure their Direct Paging Integration to route to different " + "escalation chains based on this. " + "" ) assert team_severity_checkboxes["accessory"]["type"] == "checkboxes" assert team_severity_checkboxes["accessory"]["options"] == [team_severity_important_checkbox_option]