public function DateTimeValidatorTest::testInvalidDateTimes in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/symfony/validator/Tests/Constraints/DateTimeValidatorTest.php \Symfony\Component\Validator\Tests\Constraints\DateTimeValidatorTest::testInvalidDateTimes()
@dataProvider getInvalidDateTimes
File
- vendor/
symfony/ validator/ Tests/ Constraints/ DateTimeValidatorTest.php, line 81
Class
Namespace
Symfony\Component\Validator\Tests\ConstraintsCode
public function testInvalidDateTimes($dateTime, $code) {
$constraint = new DateTime(array(
'message' => 'myMessage',
));
$this->validator
->validate($dateTime, $constraint);
$this
->buildViolation('myMessage')
->setParameter('{{ value }}', '"' . $dateTime . '"')
->setCode($code)
->assertRaised();
}