| Conditions | 1 |
| Paths | 1 |
| Total Lines | 8 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 10 | public function testIntegerRound() |
||
| 11 | { |
||
| 12 | $this->assertTrue(Decimal::fromFloat(0.4)->round()->isZero()); |
||
| 13 | $this->assertTrue(Decimal::fromFloat(0.4)->round()->equals(Decimal::fromInteger(0))); |
||
| 14 | |||
| 15 | $this->assertFalse(Decimal::fromFloat(0.5)->round()->isZero()); |
||
| 16 | $this->assertTrue(Decimal::fromFloat(0.5)->round()->equals(Decimal::fromInteger(1))); |
||
| 17 | } |
||
| 18 | |||
| 39 |