def test_start_date_after_signed_date(self):
     """Start date after max signed date is valid"""
     intervention = InterventionFactory(
         signed_by_unicef_date=datetime.date(2001, 2, 1),
         signed_by_partner_date=datetime.date(2001, 3, 1),
         signed_pd_document="random.pdf",
         start=datetime.date(2001, 4, 1))
     self.assertTrue(start_date_signed_valid(intervention))
 def test_start_date_after_signed_date(self):
     """Start date after max signed date is valid"""
     intervention = InterventionFactory(
         signed_by_unicef_date=datetime.date(2001, 2, 1),
         signed_by_partner_date=datetime.date(2001, 3, 1),
         signed_pd_document="random.pdf",
         start=datetime.date(2001, 4, 1)
     )
     self.assertTrue(start_date_signed_valid(intervention))
Beispiel #3
0
 def test_start_date_after_signed_date_attachment(self):
     """Start date after max signed date is valid"""
     intervention = InterventionFactory(
         signed_by_unicef_date=datetime.date(2001, 2, 1),
         signed_by_partner_date=datetime.date(2001, 3, 1),
         start=datetime.date(2001, 4, 1))
     AttachmentFactory(file="random.pdf",
                       code="partners_intervention_signed_pd",
                       content_object=intervention)
     self.assertTrue(start_date_signed_valid(intervention))
 def test_start_date_after_signed_date_attachment(self):
     """Start date after max signed date is valid"""
     intervention = InterventionFactory(
         signed_by_unicef_date=datetime.date(2001, 2, 1),
         signed_by_partner_date=datetime.date(2001, 3, 1),
         start=datetime.date(2001, 4, 1)
     )
     AttachmentFactory(
         file="random.pdf",
         code="partners_intervention_signed_pd",
         content_object=intervention
     )
     self.assertTrue(start_date_signed_valid(intervention))