Beispiel #1
0
 def test_add_notification_flag_dry_run(self):
     add_notification_flag(self.mocked_resource, dry_run=True)
     self.assertIsNone(
         self.mocked_resource.obj.get("metadata").get("annotations").get(
             "janitor/notified", None))
Beispiel #2
0
 def test_was_notified(self):
     add_notification_flag(self.mocked_resource, dry_run=False)
     self.assertTrue(was_notified(self.mocked_resource))
Beispiel #3
0
 def test_add_notification_flag(self):
     add_notification_flag(self.mocked_resource, dry_run=False)
     self.assertEqual(
         self.mocked_resource.obj.get('metadata').get('annotations').get(
             'janitor/notified'), 'yes')