0.3, 0.1 + 0.2, false
],
[0.4 - 0.1, 0.1 + 0.2, false
],
[0.1 + 0.1 + 0.1, 0.1 + 0.2, false
],
];
} /**
* @dataProvider greaterThanDataProvider
*/
public function testGreaterThan(float
$a, float
$b, bool
$expected): void
{ static::
assertSame($expected, FloatComparator::
greaterThan($a,
$b));
} /**
* @return array{0: float, 1: float, 2: bool}[]
*/
public static function greaterThanDataProvider(): array
{ return [ [2, 1, true
],
[1.00001, 1, true
],
[0.00001, 0, true
],
[