fix(): fixed bugs with cache invalidation, notifications and guardrails

This commit is contained in:
ITQ
2026-02-24 13:16:29 +03:00
parent b27254e2fb
commit 7bf3ccee5c
14 changed files with 290 additions and 82 deletions
@@ -238,6 +238,27 @@ class NotificationEnqueueTest(TestCase):
)
self.assertEqual(len(logs), 0)
def test_enqueue_experiment_resumed(self) -> None:
rule_create(
event_type=NotificationEventType.EXPERIMENT_RESUMED,
channel=self.channel,
)
logs = notification_enqueue(
NotificationEventType.EXPERIMENT_RESUMED,
NotificationPayload(
title="Experiment Resumed",
body=f"Experiment '{self.experiment.name}' - experiment resumed.",
event_type=NotificationEventType.EXPERIMENT_RESUMED,
experiment_id=str(self.experiment.pk),
experiment_name=self.experiment.name,
),
)
self.assertEqual(len(logs), 1)
self.assertEqual(
logs[0].event_type, NotificationEventType.EXPERIMENT_RESUMED
)
self.assertEqual(logs[0].status, NotificationStatus.PENDING)
class FlushNotificationsTest(TestCase):
@override