Example #1
0
 def test_python_condition_date(self):
     memberOf = MemberOf([1, date(2010, 03, 19), 5])
     self.assertTrue(memberOf.met("2010-03-19"))
     self.assertTrue(memberOf.met(date(2010, 03, 19)))
     self.assertFalse(memberOf.met("2010-03-18"))
     self.assertFalse(memberOf.met(date(2010, 02, 19)))
Example #2
0
 def test_python_condition(self):
     memberOf = MemberOf([1, 2, 5, date(2010, 03, 19)])
     self.assertTrue(memberOf.met("2"))
     self.assertTrue(memberOf.met(5))
     self.assertFalse(memberOf.met(3))
     self.assertFalse(memberOf.met(None))