Skip to content

Commit e0c8bd4

Browse files
committed
Merge branch '3.1'
* 3.1: fixed CS Properly format value in UniqueEntityValidator [Translation][fallback] add missing resources in parent catalogues. removed a deprecation notice [Form] Fix show float values as choices values in ChoiceType Remove double use Statement Improved the design of the metrics in the profiler [Yaml] set arguments depending on the PHP version [Console] Fix infinite loop on missing input [HttpFoundation][Session] memcached connection should not be closed
2 parents b2010d5 + cc82ea6 commit e0c8bd4

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Tests/InlineTest.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -566,7 +566,12 @@ public function testParseTimestampAsDateTimeObject($yaml, $year, $month, $day, $
566566
$expected = new \DateTime($yaml);
567567
$expected->setTimeZone(new \DateTimeZone('UTC'));
568568
$expected->setDate($year, $month, $day);
569-
@$expected->setTime($hour, $minute, $second, 1000000 * ($second - (int) $second));
569+
570+
if (PHP_VERSION_ID >= 70100) {
571+
$expected->setTime($hour, $minute, $second, 1000000 * ($second - (int) $second));
572+
} else {
573+
$expected->setTime($hour, $minute, $second);
574+
}
570575

571576
$this->assertEquals($expected, Inline::parse($yaml, Yaml::PARSE_DATETIME));
572577
}

0 commit comments

Comments
 (0)