Example #1
0
 public function testGetMessagesReturnsDefaultValue()
 {
     $validator = new Validator\DateStep();
     $this->assertEquals(array(), $validator->getMessages());
 }
Example #2
0
 public function testStepError()
 {
     $validator = new Validator\DateStep(array('format' => 'Y-m-d', 'baseValue' => '2012-01-23', 'step' => new DateInterval("P10D")));
     $this->assertFalse($validator->isValid('2012-02-23'));
 }