fix(): fixed bugs with cache invalidation, notifications and guardrails
This commit is contained in:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user