firefighter-incident 0.0.18__py3-none-any.whl → 0.0.20__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- firefighter/_version.py +2 -2
- firefighter/incidents/forms/select_impact.py +1 -1
- firefighter/jira_app/client.py +17 -7
- firefighter/raid/client.py +2 -0
- firefighter/raid/forms.py +6 -2
- firefighter/raid/views/__init__.py +1 -0
- {firefighter_incident-0.0.18.dist-info → firefighter_incident-0.0.20.dist-info}/METADATA +1 -1
- {firefighter_incident-0.0.18.dist-info → firefighter_incident-0.0.20.dist-info}/RECORD +21 -15
- firefighter_tests/test_jira_app/__init__.py +1 -0
- firefighter_tests/test_jira_app/conftest.py +24 -0
- firefighter_tests/test_jira_app/test_jira_client_watchers.py +135 -0
- firefighter_tests/test_raid/test_raid_alert_p4_p5.py +255 -0
- firefighter_tests/test_raid/test_raid_client.py +32 -0
- firefighter_tests/test_raid/test_raid_forms.py +61 -3
- firefighter_tests/test_raid/test_raid_serializers.py +47 -0
- firefighter_tests/test_raid/test_zendesk_integration.py +198 -0
- firefighter_tests/test_slack/test_conversation_tags.py +344 -0
- firefighter_tests/test_slack/views/modals/test_update_status.py +7 -9
- {firefighter_incident-0.0.18.dist-info → firefighter_incident-0.0.20.dist-info}/WHEEL +0 -0
- {firefighter_incident-0.0.18.dist-info → firefighter_incident-0.0.20.dist-info}/entry_points.txt +0 -0
- {firefighter_incident-0.0.18.dist-info → firefighter_incident-0.0.20.dist-info}/licenses/LICENSE +0 -0
|
@@ -331,28 +331,26 @@ class TestUpdateStatusModal:
|
|
|
331
331
|
trigger_incident_workflow.assert_not_called()
|
|
332
332
|
|
|
333
333
|
@staticmethod
|
|
334
|
-
def test_can_close_when_all_conditions_met(mocker: MockerFixture) -> None:
|
|
334
|
+
def test_can_close_when_all_conditions_met(mocker: MockerFixture, priority_factory, environment_factory) -> None:
|
|
335
335
|
"""Test that closing is allowed when all conditions are met for P3+ incidents."""
|
|
336
336
|
# Create a user first
|
|
337
337
|
user = UserFactory.build()
|
|
338
338
|
user.save()
|
|
339
339
|
|
|
340
|
+
# Create P3 priority (needs_postmortem=False) and non-PRD environment
|
|
341
|
+
p3_priority = priority_factory(value=3, name="P3", needs_postmortem=False)
|
|
342
|
+
stg_environment = environment_factory(value="STG", name="Staging")
|
|
343
|
+
|
|
340
344
|
# Create a P3+ incident in MITIGATED status with all conditions met
|
|
341
345
|
incident = IncidentFactory.build(
|
|
342
346
|
_status=IncidentStatus.MITIGATED,
|
|
343
347
|
created_by=user,
|
|
348
|
+
priority=p3_priority,
|
|
349
|
+
environment=stg_environment,
|
|
344
350
|
)
|
|
345
351
|
# IMPORTANT: Save the incident so it has an ID for the form to reference
|
|
346
352
|
incident.save()
|
|
347
353
|
|
|
348
|
-
# Mock needs_postmortem to return False (P3+ incident)
|
|
349
|
-
mocker.patch.object(
|
|
350
|
-
type(incident),
|
|
351
|
-
"needs_postmortem",
|
|
352
|
-
new_callable=PropertyMock,
|
|
353
|
-
return_value=False
|
|
354
|
-
)
|
|
355
|
-
|
|
356
354
|
# Mock can_be_closed to return True (all conditions met)
|
|
357
355
|
mocker.patch.object(
|
|
358
356
|
type(incident),
|
|
File without changes
|
{firefighter_incident-0.0.18.dist-info → firefighter_incident-0.0.20.dist-info}/entry_points.txt
RENAMED
|
File without changes
|
{firefighter_incident-0.0.18.dist-info → firefighter_incident-0.0.20.dist-info}/licenses/LICENSE
RENAMED
|
File without changes
|