public function RangeValidatorTest::getLaterThanTwentiethMarch2014 in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/validator/Tests/Constraints/RangeValidatorTest.php \Symfony\Component\Validator\Tests\Constraints\RangeValidatorTest::getLaterThanTwentiethMarch2014()
File
- vendor/
symfony/ validator/ Tests/ Constraints/ RangeValidatorTest.php, line 229
Class
Namespace
Symfony\Component\Validator\Tests\ConstraintsCode
public function getLaterThanTwentiethMarch2014() {
// The provider runs before setUp(), so we need to manually fix
// the default timezone
$this
->setDefaultTimezone('UTC');
$tests = array(
array(
new \DateTime('March 21, 2014'),
'Mar 21, 2014, 12:00 AM',
),
array(
new \DateTime('March 9, 2015'),
'Mar 9, 2015, 12:00 AM',
),
);
if (PHP_VERSION_ID >= 50500) {
$tests[] = array(
new \DateTimeImmutable('March 21, 2014'),
'Mar 21, 2014, 12:00 AM',
);
$tests[] = array(
new \DateTimeImmutable('March 9, 2015'),
'Mar 9, 2015, 12:00 AM',
);
}
$this
->restoreDefaultTimezone();
return $tests;
}