示例#1
0
 public function testIsGettingErrorMessage()
 {
     $constraint = new DateRange('today', '+3 days');
     $this->assertFalse($constraint->validate('yesterday'));
     $this->assertEquals('[field] Date is not between "today" and "+3 days"', $constraint->getErrorMessage('field'));
 }