예제 #1
0
 def test_direct_cp(self):
     cp = CountryProgrammeFactory(to_date=self.lead_date)
     InterventionFactory(
         document_type=Intervention.PD,
         end=self.lead_date + datetime.timedelta(days=10),
         country_programme=cp,
     )
     mock_send = Mock()
     with patch(self.send_path, mock_send):
         utils.send_pca_required_notifications()
     self.assertEqual(mock_send.call_count, 1)
예제 #2
0
파일: test_utils.py 프로젝트: unicef/etools
 def test_direct_cp(self):
     cp = CountryProgrammeFactory(to_date=self.lead_date)
     InterventionFactory(
         document_type=Intervention.PD,
         end=self.lead_date + datetime.timedelta(days=10),
         country_programme=cp,
     )
     mock_send = Mock()
     with patch(self.send_path, mock_send):
         utils.send_pca_required_notifications()
     self.assertEqual(mock_send.call_count, 1)
예제 #3
0
파일: tasks.py 프로젝트: adi130987/etools
def check_pca_required():
    send_pca_required_notifications()
예제 #4
0
 def handle(self, *args, **options):
     send_pca_required_notifications()