10000 Correct compare float data · symfony/symfony@3a088c1 · GitHub
[go: up one dir, main page]

Skip to content

Commit 3a088c1

Browse files
author
Peter Gribanov
committed
Correct compare float data
1 parent ad522a9 commit 3a088c1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/Stopwatch/Tests/StopwatchPeriodTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function testGetEndTime($end, $useMorePrecision, $expected)
4040
public function testGetDuration($start, $end, $useMorePrecision, $duration)
4141
{
4242
$period = new StopwatchPeriod($start, $end, $useMorePrecision);
43-
$this->assertSame($duration, $period->getDuration());
43+
$this->assertEqualsWithDelta($duration, $period->getDuration(), PHP_FLOAT_EPSILON);
4444
}
4545

4646
public function provideTimeValues()

0 commit comments

Comments
 (0)
0